|
1 | | -ABOUT HOPE Country Report |
| 1 | +HOPE Country Report |
2 | 2 | ========================= |
3 | 3 |
|
4 | 4 |
|
5 | | -## Contributing |
| 5 | +[](https://github.com/unicef/hope-country-report/actions/workflows/ci.yml) |
| 6 | +[](https://codecov.io/github/unicef/hope-country-report) |
| 7 | +[](https://unicef.github.io/hope-country-report/) |
| 8 | +[](https://hub.docker.com/r/unicef/hope-country-report/tags) |
6 | 9 |
|
7 | | -### System Requirements |
| 10 | +Hope Country Report (HCR) is a pivotal component within the Hope platform, specifically designed to empower UNICEF country offices with the ability to generate customized reports tailored to their unique requirements. |
8 | 11 |
|
9 | | -- python 3.12 |
10 | | -- [direnv](https://direnv.net/) - not mandatory but strongly recommended |
11 | | -- [uv](https://docs.astral.sh/uv/) |
12 | 12 |
|
13 | | -## Configure development environment |
| 13 | +## Documentation |
14 | 14 |
|
15 | | -**WARNING** |
16 | | -> HCR implements **security first** policy. It means that configuration default values are "almost" production compliant. |
17 | | -> |
18 | | -> Es. `DEBUG=False` or `SECURE_SSL_REDIRECT=True`. |
19 | | -> |
20 | | -> Be sure to run `./manage.py env --check` and `./manage.py env -g all` to check and display your configuration |
21 | | -
|
22 | | - |
23 | | - |
24 | | -### 1. Clone repo and install requirements |
25 | | - git clone https://github.com/unicef/hope-country-report |
26 | | - cd hope-country-report |
27 | | - uv sync |
28 | | - |
29 | | -### 2. configure your environment |
30 | | - |
31 | | -Uses `./manage.py env` to configure your environment |
32 | | - |
33 | | - ./manage.py env > .evnvrc |
34 | | - |
35 | | -Customize your env for development: |
36 | | - |
37 | | - export DEBUG=True |
38 | | - export SESSION_COOKIE_NAME="hcr_test_session" |
39 | | - export SESSION_COOKIE_DOMAIN="" |
40 | | - export SESSION_COOKIE_SECURE=False |
41 | | - export SECURE_HSTS_SECONDS=0 |
42 | | - export SECURE_HSTS_PRELOAD=False |
43 | | - export CSRF_COOKIE_SECURE=False |
44 | | - export SECURE_SSL_REDIRECT=False |
45 | | - export CELERY_TASK_ALWAYS_EAGER=True |
46 | | - export AUTHENTICATION_BACKENDS="hope_country_report.utils.tests.backends.AnyUserAuthBackend" |
47 | | - export SIGNING_BACKEND="hope_country_report.utils.signer.DebugSigner" |
48 | | - |
49 | | - |
50 | | -and check required (and optional) variables to put |
51 | | - |
52 | | - ./manage.py env --check |
53 | | - |
54 | | - |
55 | | -### 3. Run upgrade to run migrations and initial setup |
56 | | - |
57 | | - ./manage.py upgrade |
58 | | - |
59 | | -### 4. (Optional) Create some sample data |
60 | | - |
61 | | - ./manage.py demo |
62 | | - |
63 | | -> If `DEBUG=True` and `AUTHENTICATION_BACKENDS="hope_country_report.utils.tests.backends.AnyUserAuthBackend"` you can login using any username/password. Note that: |
64 | | -
|
65 | | -> - If the username is ADMIN_EMAIL you will be superuser |
66 | | -> - If username starts with `admin` will be created a superuser |
67 | | -> - If username starts with `user` will be created a standard user (no staff, no admin) |
| 15 | +- Documentation: https://unicef.github.io/hope-country-report/ |
| 16 | +- Tutorials : https://unicef.github.io/hope-country-report/tutorials/ |
0 commit comments