diff --git a/Dockerfile b/Dockerfile index 5c02112..24040ea 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,4 +12,4 @@ COPY --from=builder extracted/application/ ./ EXPOSE 8080 -ENTRYPOINT ["java", "org.springframework.boot.loader.JarLauncher"] \ No newline at end of file +ENTRYPOINT ["java", "org.springframework.boot.loader.launch.JarLauncher"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 0d6077d..fee357c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -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