遵循本教程,请访问:https://docs.docker.com/compose/wordpress/
运行码头-我得到:
Initializing database
[Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
[ERROR] --initialize specified but the data directory has files in it. Aborting.
[ERROR] Aborting尝试按照这里的建议添加参数:https://github.com/docker-library/mysql/issues/186 https://github.com/docker-library/mysql/issues/69
但这似乎行不通:
services:
db:
image: mysql:5.7
command: ["mysqld", "--ignore-db-dir=lost+found", "--explicit_defaults_for_timestamp"]
volumes:
- db_data:/var/lib/mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: somewordpress
MYSQL_DATABASE: wordpress
MYSQL_USER: wordpress
MYSQL_PASSWORD: wordpress还有别的解决办法吗?
发布于 2019-10-23 17:02:41
https://stackoverflow.com/questions/50953278
复制相似问题