-
-
Save knjk04/035feae0b78390399d72870189f3e452 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.9' | |
services: | |
db: | |
image: postgres:12 # 12 is the latest Flyway supported version | |
container_name: db | |
restart: always | |
environment: | |
- POSTGRES_DB=books_api | |
- POSTGRES_USER=dbuser | |
- POSTGRES_PASSWORD=dbpassword | |
ports: | |
- "5432:5432" | |
booksapi: | |
image: booksapi | |
container_name: booksapi | |
build: | |
context: . | |
dockerfile: ./Dockerfile | |
args: | |
mvn_arg: clean package | |
environment: | |
- POSTGRES_DATABASE=books_api | |
- POSTGRES_USER=dbuser | |
- POSTGRES_PASSWORD=dbpassword | |
- POSTGRES_HOSTNAME=db | |
- POSTGRES_PORT=5432 | |
ports: | |
- "8080:8080" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment