Skip to content

Commit

Permalink
feat: Correct docker setup
Browse files Browse the repository at this point in the history
  • Loading branch information
Knoblauchpilze committed Mar 30, 2024
1 parent 8bec058 commit dadd7c6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@

user-service-docker:
docker build --tag user-service -f build/users/Dockerfile .
user-service-build:
docker build --tag user-service -f build/users/Dockerfile .

user-service-run:
docker run -p 5432 -p 60001:60001 user-service
2 changes: 2 additions & 0 deletions build/users/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,7 @@ COPY --from=builder build/bin bin/
# https://stackoverflow.com/questions/21553353/what-is-the-difference-between-cmd-and-entrypoint-in-a-dockerfile
WORKDIR /app/bin
ENV ENV_DATABASE_PORT=5500
# https://stackoverflow.com/questions/68173651/connecting-to-a-localhost-postgres-database-from-within-a-docker-container
ENV ENV_DATABASE_HOST="172.17.0.1"
EXPOSE 60001
CMD ["./users"]

0 comments on commit dadd7c6

Please sign in to comment.