- Homebrew
- MacOS package manager
- Poetry
- Backend dependency manager
- yarn
- Frontend dependency manager
- pyenv
- Python version manager. Lets you easily install the same Python version that Samfundet4 expects.
First clone the Samfundet4 repository.
git clone git@github.com:Samfundet/Samfundet4.git
Install the frontend dependencies
cd Samfundet4/frontend
yarn
Install the backend dependencies
cd ../backend
poetry install
Then apply migrations and run seed script (the seed script adds test data to our database)
poetry run python3 manage.py migrate
poetry run python3 manage.py seed
Both the backend
and frontend
directories have an .env.example
file. In each directory, copy this file to .env
and adjust any values as needed. You may for example want to change the default Django superuser username and
password (DJANGO_SUPERUSER_USERNAME
and DJANGO_SUPERUSER_USERNAME
).
Start backend:
cd backend
poetry run python3 manage.py runserver
Start frontend:
cd frontend
yarn start
Now that you've got the project up and running, check out the post-install instructions: