Secrets need both global and local per-service declaration, otherwise fails as "not found". Local configuration added for both app and db.
@@ -92,6 +92,8 @@ services:
volumes:
- ./data:/data
- ./letsencrypt:/etc/letsencrypt
+ secrets:
+ - MYSQL_PWD
depends_on:
- db
db:
@@ -106,6 +108,9 @@ services:
MYSQL_PASSWORD__FILE: /run/secrets/MYSQL_PWD
- ./data/mysql:/var/lib/mysql
+ - DB_ROOT_PWD
```