Last active
March 26, 2020 23:07
-
-
Save tiagoportaluppi/5154a0d825d4c6181511eac063667c5c to your computer and use it in GitHub Desktop.
Desenvolvimento web em JSP com Docker + PostgreSQL + Tomcat
This file contains hidden or 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.5' | |
services: | |
postgres: | |
container_name: postgres | |
image: postgres | |
environment: | |
POSTGRES_USER: ${POSTGRES_USER:-postgres} | |
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres} | |
PGDATA: /data/postgres | |
volumes: | |
- postgres:/data/postgres | |
ports: | |
- "5432:5432" | |
restart: unless-stopped | |
pgadmin: | |
container_name: pgadmin | |
image: dpage/pgadmin4 | |
environment: | |
PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL:[email protected]} | |
PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD:-admin} | |
volumes: | |
- pgadmin:/root/.pgadmin | |
ports: | |
- "${PGADMIN_PORT:-5050}:80" | |
restart: unless-stopped | |
tomcat: | |
build: . | |
container_name: projeto-um | |
volumes: | |
- ./build/web:/usr/local/tomcat/webapps/<YOUR_PROJECT_FOLDER> | |
entrypoint: "catalina.sh run" | |
ports: | |
- "8888:8080" | |
links: | |
- postgres | |
depends_on: | |
- postgres | |
volumes: | |
postgres: | |
pgadmin: |
This file contains hidden or 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
FROM tomcat:9.0.1-jre8-alpine | |
COPY ./build/web /usr/local/tomcat/webapps/<YOUR_PROJECT_FOLDER> | |
CMD ["catalina.sh", "run"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment