Skip to content

Deployment of server & website

Liam Boddin edited this page Aug 16, 2023 · 19 revisions

Local deployment

This describes a local, lightweight deployment to work with.

Database

cd Railtrail/Server
docker-compose -f docker-compose-dev.yml build
docker-compose -f docker-compose-dev.yml up

Express-Backend-Server

Get environment variables

Rename .env.example to .env

Start server

cd Railtrail/Server
npx prisma generate
npx prisma db push
npm run generate-guards       # Currently not used
npm run start

Frontend

Get environment variables

Rename .env.development to .env

Start server

cd Railtrail/Website
npm i
npm run build
npm run start

Vehicle simulator

export BACKEND_URI=http://localhost:8080/api/oyster/lorawan
cd Railtrail/vehicle-simulator
python src/main.py
Clone this wiki locally