feat: add Dockerfile and update docker-compose

This commit is contained in:
2026-02-24 15:25:54 +03:00
parent 5829aa9393
commit bca8a08469
2 changed files with 12 additions and 0 deletions

11
Dockerfile Normal file
View File

@@ -0,0 +1,11 @@
FROM eclipse-temurin:17-jdk-alpine AS build
WORKDIR /app
COPY pom.xml .
COPY src ./src
RUN apk add --no-cache maven && mvn clean package -DskipTests
FROM eclipse-temurin:17-jre-alpine
WORKDIR /app
COPY --from=build /app/target/*.jar app.jar
EXPOSE 8080
ENTRYPOINT ["java", "-jar", "app.jar"]

View File

@@ -32,6 +32,7 @@ services:
SPRING_DATASOURCE_PASSWORD: postgres SPRING_DATASOURCE_PASSWORD: postgres
APP_JWT_SECRET: 404E635266556A586E3272357538782F413F4428472B4B6250645367566B5970 APP_JWT_SECRET: 404E635266556A586E3272357538782F413F4428472B4B6250645367566B5970
APP_JWT_EXPIRATION: 86400000 APP_JWT_EXPIRATION: 86400000
APP_CARD_ENCRYPTION_KEY: 1234567890123456
volumes: volumes:
postgres_data: postgres_data: