참고 : Stacks = Docker-compose
version: "3.3"
services:
postgres:
image: postgres:10.23-bullseye
volumes: # volume
- type: volume
source: postgres-data
target: /var/lib/postgresql/data
volume:
nocpy: true
- type: bind
source: /usr/local/docker/postgres-data
target: /data/compose/64/postgres-data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
environment:
POSTGRES_PASSWORD: postgres
ports:
- 5432:5432
restart: always
networks:
- bridge
adminer:
image: adminer
restart: always
ports:
- 9999:8080
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
tomcat:
image: my-tomcat-new
restart: always
ports:
- 8080:8080
- 8005:8005
- 8443:8443
working_dir: /usr/local/tomcat
environment:
- CATALINA_HOME=/usr/local/tomcat
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
mongo-db:
image: my-mongodb
ports:
- 27017:27017
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- tomcat
networks:
- bridge
volumes: # volume
- type: volume
source: mongodb-configdb
target: /data/configdb
volume:
nocpy: true
- type: volume
source: mongodb-datadb
target: /data/db
volume:
nocpy: true
- type: volume
source: mongodb-usr-docekr-mongodb-data
target: /usr/docekr/mongodb/data
volume:
nocpy: true
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
nginxForTomcat:
image: my-nginx-for-tomcat
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
ports:
- 8880:80
restart: always
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
depends_on:
- tomcat
nginxForGateway:
image: my-nginx-for-gateway
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
ports:
- 80:80
restart: always
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
depends_on:
- tomcat
node-menu:
image: my-node-menu
ports:
- 8092:8092
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-graph:
image: my-node-graph
ports:
- 8098:8098
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-diagram:
image: my-node-diagram
ports:
- 8096:8096
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-alarm:
image: my-node-alarm
ports:
- 8094:8094
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
sfsb-api:
image: my-sfsb-api
ports:
- 9092:9092
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
volumes:
postgres-data:
mongodb-configdb:
mongodb-datadb:
mongodb-usr-docekr-mongodb-data:
networks:
bridge:
external: true
version: "3.3"
services:
postgres:
image: postgres:10.23-bullseye
volumes: # volume
- type: volume
source: postgres-data
target: /var/lib/postgresql/data
volume:
nocpy: true
- type: bind
source: /usr/local/docker/postgres-data
target: /data/compose/64/postgres-data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
environment:
POSTGRES_PASSWORD: postgres
ports:
- 5432:5432
restart: always
networks:
- bridge
adminer:
image: adminer
restart: always
ports:
- 9999:8080
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
tomcat:
image: my-centos7-tomcat
restart: always
ports:
- 8080:8080
- 8005:8005
- 8443:8443
working_dir: /usr/local/tomcat
environment:
- CATALINA_HOME=/usr/local/tomcat
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
mongo-db:
image: my-mongodb
ports:
- 27017:27017
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- tomcat
networks:
- bridge
volumes: # volume
- type: volume
source: mongodb-configdb
target: /data/configdb
volume:
nocpy: true
- type: volume
source: mongodb-datadb
target: /data/db
volume:
nocpy: true
- type: volume
source: mongodb-usr-docekr-mongodb-data
target: /usr/docekr/mongodb/data
volume:
nocpy: true
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
nginxForTomcat:
image: my-nginx-for-tomcat:230227
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
ports:
- 8880:80
restart: always
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
depends_on:
- tomcat
nginxForGateway:
image: my-nginx-for-gateway:latest
logging:
driver: "json-file"
options:
max-file: "3"
max-size: "1g"
ports:
- 80:80
restart: always
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
depends_on:
- tomcat
node-menu:
image: my-node-menu
ports:
- 8092:8092
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-graph:
image: my-node-graph
ports:
- 8098:8098
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-diagram:
image: my-node-diagram
ports:
- 8096:8096
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-alarm:
image: my-node-alarm
ports:
- 8094:8094
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- mongo-db
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
sfsb-api:
image: my-sfsb-api
ports:
- 9092:9092
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- postgres
networks:
- bridge
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
local-tunnel-client:
image: local-tunnel-client
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
depends_on:
- tomcat
networks:
- host
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
node-manager:
image: node-manager-test
logging:
driver: "json-file"
options:
max-file: "5"
max-size: "1g"
networks:
- host
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
volumes:
postgres-data:
mongodb-configdb:
mongodb-datadb:
mongodb-usr-docekr-mongodb-data:
networks:
bridge:
external: true
host:
external: true