A travel expense manager made with Django, GraphQL, Next.js and Tailwind CSS
⚠️ Warning: WIP. Do not use in a production environment.
1. Download or clone repo
git clone https://github.com/vreaxe/travel-expense-manager.git
2. Create the .env files inside the "backend" and "clients" directories and change the environment variables
"backend" folder:
DEBUG=True
SECRET_KEY=something
GRAPHIQL=True
DB_NAME=travel_expense_manager
DB_USER=root
DB_PASSWORD=secret
DB_HOST=database
DB_PORT=3306
CORS_ORIGIN_WHITELIST=http://127.0.0.1,http://localhost
"clients" folder:
NODE_ENV=local
GRAPHQL_URL_CLIENT_SIDE=http://localhost:8000/graphql/
GRAPHQL_URL_SERVER_SIDE=http://backend:8000/graphql/
APP_NAME=Travel Expense Manager
3. Build and run Docker containers
docker-compose -f docker-compose.dev.yml up -d --build
4. Migrate
docker exec tem-dev-backend python manage.py migrate --noinput
5. Create a superuser
docker exec -it tem-dev-backend python manage.py createsuperuser
6. Now you can access the backend at http://localhost:8000 and the frontend at http://localhost:3000
7. Sync currencies and countries (optional - you can create them manually through the Django admin panel)
docker exec tem-dev-backend python manage.py sync_countries
docker exec tem-dev-backend python manage.py sync_currencies