version: '3'
networks:
iotnet:
driver: 'bridge'
services:
mysql:
image: mysql:5.7
command: --default-authentication-plugin=mysql_native_password
restart: always
ports:
- "3306:3306"
volumes:
- /app/dc-mysql/conf.d:/etc/mysql/conf.d
- /app/dc-mysql/mysql.conf.d:/etc/mysql/mysql.conf.d/
- /app/dc-mysql/data:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: 123456
networks:
iotnet:
aliases:
- mysql-net
redis:
image: redis:latest
restart: always
volumes:
- /app/redis/redis.conf:/etc/redis/redis.conf
- /app/redis/data:/data
ports:
- "6379:6379"
command:
redis-server /etc/redis/redis.conf --appendonly yes
networks:
iotnet:
aliases:
- redis-net