mirror of
https://github.com/wger-project/wger.git
synced 2026-02-19 07:50:55 +01:00
Bower is deprecated and was also making some trouble under certain circumstances such as Docker, where sometimes it would download the files to the wrong folder. Hopefully this results in less headaches.
66 lines
1.5 KiB
ReStructuredText
66 lines
1.5 KiB
ReStructuredText
.. _development:
|
|
|
|
Development
|
|
===========
|
|
|
|
You can safely install from master, it is almost always in a usable
|
|
and stable state.
|
|
|
|
Virtual environment
|
|
~~~~~~~~~~~~~~~~~~~
|
|
|
|
::
|
|
|
|
$ python3 -m venv venv-wger
|
|
$ source venv-wger/bin/activate
|
|
|
|
|
|
Get the code
|
|
~~~~~~~~~~~~
|
|
::
|
|
|
|
$ git clone https://github.com/wger-project/wger.git src
|
|
$ cd src
|
|
$ WGER_PATH=$(pwd)
|
|
|
|
Install Requirements
|
|
~~~~~~~~~~~~~~~~~~~~
|
|
::
|
|
|
|
$ pip install -r requirements_devel.txt
|
|
$ npm install yarn
|
|
$ python setup.py develop
|
|
|
|
Install application
|
|
~~~~~~~~~~~~~~~~~~~
|
|
|
|
This will download the required JS and CSS libraries and create a SQlite
|
|
database and populate it with data on the first run::
|
|
|
|
|
|
$ wger create_settings \
|
|
--settings-path $WGER_PATH/settings.py \
|
|
--database-path $WGER_PATH/database.sqlite
|
|
$ wger bootstrap \
|
|
--settings-path $WGER_PATH/settings.py \
|
|
--no-start-server
|
|
|
|
You can of course also use other databases such as postgres or mariaDB. Create
|
|
a database and user and edit the DATABASES settings before calling bootstrap.
|
|
Take a look at the :ref:`prod_postgres` on apache on how that could look like.
|
|
|
|
Start the server
|
|
----------------
|
|
|
|
After the first run you can just use django's development server::
|
|
|
|
$ python manage.py runserver
|
|
|
|
That's it. You can log in with the default administrator user:
|
|
|
|
* **username**: admin
|
|
* **password**: admin
|
|
|
|
You can start the application again with the django server with
|
|
``python manage.py runserver``.
|