Note This repository is now archived and has moved to a new home.
A website to help the anti-coup resistance movement in Sudan. See sudan-art.com.
This site was inspired by the Burmese website Three Fingers, used to support the anti-coup resistance movement in Myanmar.
- Digital Ocean
- Docker
- Python
- Django
- Django Rest Framework
- Django Storages
- CORS Headers
- Javascript
- React
- React testing library
- React Router
- Chakra UI
- Clone the github repository
- Run
pip install -r sudan-art/django-backend/requirements-dev.txtand thenpre-commit installto set up the pre-commit hook. - Hit
cd sudan-art/react-frontendandnpm installto set up the frontend dependencies. - Check the frontend is ok by hitting
cd sudan-art/react-frontendand thennpm testand selectato run all the tests. - Assuming that goes OK, create a file to contain all the environment variables for the app. Hit
touch envto create the file in the root directory of the repository, the same directory you just rangit branchin. - Populate this file. You need the following values:
DJANGO_SECRET_KEY=<make your own secret key>
DJANGO_SETTINGS_MODULE=django_backend.dev_settings
- To run python tests, hit
python manage.py test sudan_art.tests --settings=django_backend.test_settings - Now from the root directory of the repository, run
docker-compose -f docker-compose-dev.yml --env-file env up --build -d. This will take some time, so check there are no basic errors then go have a break - Run
docker ps -ato get the id of the django container - it's also the id output by the command above - Run
docker exec -it <container id goes here> /bin/bashto get a shell on the Django container - Run
python manage.py migrateto run migrations - Run
python manage.py test sudan_art.teststo run the test suite - Hit exit to quit your shell session on the Docker container
- Navigate to
https://localhost:3000to see the frontend of the site andhttps://localhost:8000to see the backend. The frontend can take a while to load so hitdocker logs <frontend container id>to check what's going on if you're out of patience
Contributions of all kind are very welcome 😍 ! Please read the guide to get started.
