#### 镜像上传
# 仓库私服: ***
# 第一步:上传镜像到docker仓库
# 第二步: 将此yml文件上传服务器,执行启动命令 docker-compose -f ./docker-compose-server.yml up
version: '2'
services:
twqc-jenkins:
image: ***
user: root
ports:
- 8080:8080
- 50000:50000
restart: always
container_name: boot-jenkins
hostname: boot-jenkins
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
- /usr/bin/docker:/usr/bin/docker
- /var/run/docker.sock:/var/run/docker.sock
- /usr/local/bin/docker-compose:/usr/local/bin/docker-compose
- /data/jenkins_home:/var/jenkins_home
boot-mysql:
image: ***
environment:
MYSQL_ROOT_PASSWORD: ***
MYSQL_ROOT_HOST: '%'
TZ: Asia/Shanghai
restart: always
container_name: boot-mysql
command: [
'mysqld',
'--innodb-buffer-pool-size=80M',
'--character-set-server=utf8mb4',
'--collation-server=utf8mb4_unicode_ci',
'--default-time-zone=+8:00',
'--lower-case-table-names=1'
]
ports:
- 3307:3307
volumes:
- /data/mysql/data:/var/lib/mysql
- /data/mysql/conf/my.cnf:/etc/my.cnf
- /data/mysql/log:/var/log/mysql
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-nacos:
image: ***
restart: on-failure
container_name: boot-nacos
network_mode: host
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
- /data/nacos/config:/boot-nacos/config
boot-gateway:
image: ***
restart: on-failure
ports:
- 9999:9999
container_name: boot-gateway
hostname: boot-gateway
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-system:
image: ***
container_name: boot-system
hostname: boot-system
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-lowcode:
image: ***
container_name: boot-lowcode
hostname: boot-lowcode
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
- /data/data/lowcode:/boot-lowcode/tmp_zip
boot-dcp:
image: ***
container_name: boot-dcp
hostname: boot-dcp
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-datasource:
image: ***
container_name: boot-datasource
hostname: boot-datasource
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-sg:
image: ***
container_name: boot-sg
hostname: boot-sg
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-sc:
image: ***
container_name: boot-sc
hostname: boot-sc
restart: on-failure
volumes:
- /etc/localtime:/etc/localtime
- /etc/timezone:/etc/timezone
boot-minio:
image: ***
volumes:
- /data/minio:/data # 持久化地址
ports:
- 9000:9000
container_name: boot-minio
restart: always
environment:
MINIO_ACCESS_KEY: minioadmin # 账号
MINIO_SECRET_KEY: admin123456 #密码
MINIO_PROMETHEUS_AUTH_TYPE: public
command: server /data
boot-ui:
image: ***
container_name: boot-ui
restart: always
volumes:
- /data/boot-ui/config.js:/var/www/html/config.js # 持久化配置文件
ports:
- 80:80
boot-mobile:
image: ***
container_name: boot-mobile
restart: always
volumes:
- /data/boot-mobile/config.js:/var/www/html/config.js # 持久化配置文件
ports:
- 81:81
wq-data-visual-bigscreen-designer:
image: ***
restart: on-failure
ports:
- 82:80
container_name: wq-data-visual-bigscreen-designer
hostname: wq-data-visual-bigscreen-designer
volumes:
- /data/bigscreen-designer/config.js:/var/www/html/config.js # 持久化配置文件
boot-elasticsearch:
image: ***
ports:
- 9200:9200
- 9300:9300
environment:
ES_JAVA_OPTS: '-Xms128m -Xmx1024m'
restart: always
container_name: boot-elasticsearch
hostname: boot-elasticsearch
# 注意此处往往会报挂载目录没有权限问题,简单处理的话可以chmod 777 /data/es/**,更规范的做法是创建elasticsearch用户,给指定用户授权文件夹权限
volumes:
- /data/es/config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml # 挂载配置文件
- /data/es/data:/usr/share/elasticsearch/data # 挂载数据目录
- /data/es/plugins:/usr/share/elasticsearch/plugins # 挂载插件目录
boot-elasticsearch-head:
image: ***
ports:
- 9100:9100
restart: always
container_name: boot-elasticsearch-head
hostname: boot-elasticsearch-head
Docker-compose
于 2023-04-21 15:58:16 首次发布