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.txt
and thenpre-commit install
to set up the pre-commit hook. - Hit
cd sudan-art/react-frontend
andnpm install
to set up the frontend dependencies. - Check the frontend is ok by hitting
cd sudan-art/react-frontend
and thennpm test
and selecta
to run all the tests. - Assuming that goes OK, create a file to contain all the environment variables for the app. Hit
touch env
to create the file in the root directory of the repository, the same directory you just rangit branch
in. - 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 -a
to 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/bash
to get a shell on the Django container - Run
python manage.py migrate
to run migrations - Run
python manage.py test sudan_art.tests
to run the test suite - Hit exit to quit your shell session on the Docker container
- Navigate to
https://localhost:3000
to see the frontend of the site andhttps://localhost:8000
to 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.