共计 232 个字符,预计需要花费 1 分钟才能阅读完成。
docker-compose.yml
version: '3.6'
services:
mysql:
image: mysql
secrets:
- login-password
environment:
MYSQL_ROOT_PASSWORD_FILE: /run/secrets/login-password
secrets:
login-password:
external: true
部署
docker stack deploy -c=docker-compose.yml mysql-secret
正文完