diff --git a/docs/components/.pages b/docs/components/.pages index d0e38b2..9251433 100644 --- a/docs/components/.pages +++ b/docs/components/.pages @@ -1,7 +1,7 @@ nav: - index.md - - Aurora: aurora + - Aurora: aurora.md - Kobo: kobo - Payment Gateway: pg.md - Country Report: cr.md diff --git a/docs/components/aurora/index.md b/docs/components/aurora.md similarity index 100% rename from docs/components/aurora/index.md rename to docs/components/aurora.md diff --git a/docs/components/aurora/.pages b/docs/components/aurora/.pages deleted file mode 100644 index 20253e7..0000000 --- a/docs/components/aurora/.pages +++ /dev/null @@ -1,3 +0,0 @@ -nav: - - index.md - - setup diff --git a/docs/components/aurora/setup/config.md b/docs/components/aurora/setup/config.md deleted file mode 100644 index 64e4c7a..0000000 --- a/docs/components/aurora/setup/config.md +++ /dev/null @@ -1,7 +0,0 @@ -# Setup HOPE integration - -- Add aurora_token in the user -- Add aurora_server in the Constance Config -- Fetch data from Aurora -- Associate Organizations to Business Areas -- Associate Projects to Programmes diff --git a/docs/components/aurora/setup/docker.md b/docs/components/aurora/setup/docker.md deleted file mode 100644 index 1b94a3d..0000000 --- a/docs/components/aurora/setup/docker.md +++ /dev/null @@ -1,19 +0,0 @@ -# Build and use your docker - -After you have cloned the repo, be sure to have a Reddis and PostgreSQL server running on your machine - - export ADMIN_EMAIL=admin@example.com - export ADMIN_PASSWORD=password - export DATABASE_URL=postgres://postgres:@127.0.0.1:5432/aurora - export CACHE_URL=redis://127.0.0.1:6379/1?client_class=django_redis.client.DefaultClient - - cd docker - - make build run - - -## Use provided compose.yml - - docker compose up - -navigate to http://localhost:8000/admin/ and login using `admin@example.com/password` diff --git a/docs/components/aurora/setup/virtualenv.md b/docs/components/aurora/setup/virtualenv.md deleted file mode 100644 index 45a259b..0000000 --- a/docs/components/aurora/setup/virtualenv.md +++ /dev/null @@ -1,85 +0,0 @@ -# Setup - - -Prerequisites: - -- This project uses [pdm](https://github.com/pdm-project/pdm#installation) as package manager -- A Postgres DB v14+ -- A Redis server - -!!! note - - PDM will create a virtualenv in /.venv, and install dependencies into it. - If you wand to change this behaviour please read the [PDM Documentation](https://pdm-project.org/en/latest/usage/venv/) - - -## Create virtualenvironment - -1. Checkout code - - ``` - git clone https://github.com/unicef/hope-aurora - git config branch.autosetuprebase always - - ``` - -2. In the shell: - - ``` - pdm venv create - pdm use - pdm venv activate - ``` - -3. Check your virtualenv is properly created - - ```pdm info``` - - -4. Install the package - - ``` - pdm install - pdm run pre-commit install - ``` - - -5. Add `export PYTHONPATH="$PYTHONPATH:./src"` - - -6. Check your environment: - - `./manage.py env --check` and configure the missing variables. - - !!! hint - - You can generate a list for your development environment with the command - - ./manage.py env --develop --config --pattern='export {key}={value}' - -7. Run upgrade command to properly initialize the application: - - `./manage.py upgrade --admin-email ${ADMIN_EMAIL} --admin-password ${ADMIN_PASSWORD}` - - !!! note - - Django migrations and collectstatic commands are automatically included in this step - - -## Configure environment for .direnv - -If you want to use [direnv](https://direnv.net/) and automatic loading of environment variables from a _.envrc_ file: - -``` -./manage.py env --develop --config --pattern='{key}={value}' > .envrc - -echo 'export PYTHONPATH="$PYTHONPATH:./src"' >> .envrc -echo 'eval $(pdm venv activate)' >> .envrc -echo "unset PS1" >> .envrc -``` - -!!! warning - - The first time after you have created or modified the _.envrc_ file you will have to authorize it using: - - direnv allow diff --git a/docs/components/index.md b/docs/components/index.md index aaeca6e..18d1b1d 100644 --- a/docs/components/index.md +++ b/docs/components/index.md @@ -10,7 +10,7 @@ It’s built to be scalable, adaptable, and interoperable, making it simple to i systems and platforms, ensuring smooth workflows and easy expansion as your needs grow. -- [Aurora](aurora/index.md) +- [Aurora](aurora.md) - [Kobo](kobo/index.md)