Docker Support Added
This commit is contained in:
parent
b66567406a
commit
cca9477034
5
docker/Dockerfile
Normal file
5
docker/Dockerfile
Normal file
@ -0,0 +1,5 @@
|
||||
FROM eclipse-temurin:21
|
||||
LABEL authors="indx"
|
||||
|
||||
COPY ./build/libs/NTO-Finals-0.0.1-SNAPSHOT.jar /opt/app/
|
||||
CMD ["java", "-jar", "/opt/app/NTO-Finals-0.0.1-SNAPSHOT.jar"]
|
@ -1,4 +1,19 @@
|
||||
services:
|
||||
app:
|
||||
build:
|
||||
context: ../
|
||||
dockerfile: ./docker/Dockerfile
|
||||
container_name: app
|
||||
depends_on:
|
||||
- postgres_nto
|
||||
environment:
|
||||
- SPRING_DATASOURCE_URL=jdbc:postgresql://postgres_nto:5432/application_db
|
||||
- SPRING_DATASOURCE_USERNAME=$USERNAME
|
||||
- SPRING_DATASOURCE_PASSWORD=$PASSWORD
|
||||
|
||||
ports:
|
||||
- "8081:8081"
|
||||
|
||||
postgres_nto:
|
||||
image: postgres:latest
|
||||
container_name: postgres_nto
|
||||
|
@ -5,7 +5,7 @@ spring:
|
||||
datasource:
|
||||
url: jdbc:postgresql://localhost:5429/application_db
|
||||
username: indexzero
|
||||
password: gkl370WVUPMgLhK
|
||||
password: PASSWORD
|
||||
driver-class-name: org.postgresql.Driver
|
||||
|
||||
h2:
|
||||
|
Loading…
x
Reference in New Issue
Block a user