Skip to content

Latest commit

 

History

History
106 lines (71 loc) · 2.54 KB

README.md

File metadata and controls

106 lines (71 loc) · 2.54 KB

Bikelivery Server 🚴

📌 A simple REST API server used for managing bike deliveries & showing monthly/weekly stats. Project contains NestJS app as a backend (server). Database used in this project is PostgreSQL.

GitHub package.json version (subfolder of monorepo) GitHub top language GitHub repo size

Features

  • Adding trips between two addresses with price and date
  • Editing or deleting previously added trips
  • Listing all added trips
  • Listing weekly stats containing total distance and price from current week
  • Listing monthly stats containing total distance, average distance and average price from current month splitted by days

Endpoints Documentation

📚 Documentation of all available endpoints can be found here: API Documentation

Run Locally

  • Clone repository
  git clone https://github.com/jakubcieslik99/bikelivery-server.git

ℹ️ Instructions for running server app locally:

  • Navigate to the server directory and install dependencies
  cd bikelivery-server
  pnpm install
  • Run server app in development mode
  pnpm run docker
  pnpm run dev

Deployment

ℹ️ Instructions for building and running server app in production

  • Transpile to production build
  pnpm run build
  • Run server app in production mode
  pnpm install --prod
  pnpm run migration:run
  pnpm run start

Environment Variables

⚙️ To run server app, you will need to add the following environment variables to your .env file

  • DIR (default already set for development)

  • ENV (default already set for development)

  • POSTGRES_VER

  • REDIS_VER

  • PORT

  • API_URL

  • APP_URL

  • POSTGRES_HOST

  • POSTGRES_PORT

  • POSTGRES_DB

  • POSTGRES_USER

  • POSTGRES_PASSWORD

  • REDIS_HOST

  • REDIS_PORT

  • REDIS_PASSWORD

  • COOKIE_SESSION_SECRET

  • JWT_ACCESS_TOKEN_SECRET

  • JWT_REFRESH_TOKEN_SECRET

  • GOOGLE_DIRECTIONS_API_KEY

Languages

🔤 Available API messages languages: EN

Feedback

If you have any feedback, please reach out to me at ✉️ [email protected]

Authors