Skip to content

Commit

Permalink
Containerize backend and fix Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
rsh-12 committed May 12, 2024
1 parent f2d0f32 commit e5f8676
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ COPY --from=builder extracted/application/ ./

EXPOSE 8080

ENTRYPOINT ["java", "org.springframework.boot.loader.JarLauncher"]
ENTRYPOINT ["java", "org.springframework.boot.loader.launch.JarLauncher"]
13 changes: 13 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
version: '3.8'

services:
backend:
build: .
image: money-tracker/backend
container_name: backend
ports:
- "8080:8080"
environment:
SPRING_DATASOURCE_USERNAME: ${POSTGRES_USER}
SPRING_DATASOURCE_PASSWORD: ${POSTGRES_PASSWORD}
SPRING_DATASOURCE_URL: jdbc:postgresql://postgres/${POSTGRES_DB}
depends_on:
- postgres

postgres:
image: postgres:15
container_name: postgres
Expand Down

0 comments on commit e5f8676

Please sign in to comment.