π Build a RESTful API on Go: Fiber, PostgreSQL, JWT and Swagger docs in isolated Docker containers.
Fiber, PostgreSQL, JWT and Swagger docs in isolated Docker containers.
π The full article is published on March 22, 2021, on Dev.to: https://dev.to/koddr/build-a-restful-api-on-go-fiber-postgresql-jwt-and-swagger-docs-in-isolated-docker-containers-475j
.env.example
to .env
and fill it with your environment values.make docker.run
# Process:
# - Generate API docs by Swagger
# - Create a new Docker network for containers
# - Build and run Docker containers (Fiber, PostgreSQL)
# - Apply database migrations (using github.com/golang-migrate/migrate)
If you want more articles like this on this blog, then post a comment below and subscribe to me. Thanks! π
And, of course, you can support me by donating at LiberaPay. Each donation will be used to write new articles and develop non-profit open-source projects for the community.
MIT Β© Vic ShΓ³stak & True web artisans.
Windows:
$ set CGO_ENABLED=0 && go build -ldflags="-w -s -X 'main.version=1.0.1'" .