/product-feedback-app

Technologies: Go, gin, golang-migrate/migrate, JWT, PostgreSQL, Docker compose, logrus, Heroku, GitHub Actions, Swagger, websocket.

Primary LanguageGo

Product Feedback App Backend

CI codecov

Technologies

How to Start

  1. Run make up to spin up PostgreSQL DB with Docker compose.
  2. Install golang-migrate/migrate and run make migrate_up to run migrations.
  3. Create .env file (see .env.example as an example).
  4. Run make run to start server.

Done

  • Authentication with GitHub & JWT
  • Create, Read operations with Users
  • Create, Read, Update, Delete operations with Feedback
  • Create, Read operations with Comments
  • Create, Read, Delete a Votes
  • Deployed (Heroku), endpoint
  • Add Swagger documentation
  • Setup CICD
  • Use Websocket to notify users about updates of feedback, comments & votes

Todo

  • Add unit-tests
  • Add api-tests
  • Update, Delete operations with Comments
  • Update, Delete operations with Users

How to run locally

  1. Install Docker. Here is an example how it can be done for Windows link
  2. Verify that it's installed and workes docker version.
  3. Run docker volume create product-feedback-db to create a volume for PostgreSQL database to persist data.
  4. Verify that it's created docker volume ls (should be seen in the output).
  5. Add .env file to the root of the project. See .env.example for reference.
  6. Run docker compose up -d from the root of the project.
  7. App should start and be available on http://localhost:8000. Also, you may check Swagger documentation on http://localhost:8000/docs.
  8. Run docker compose down to clean up.