Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
eecacd1074 | |||
20e811f8de |
@@ -1,11 +1,11 @@
|
||||
FROM mysql:5.7.28
|
||||
FROM mysql:5.7
|
||||
MAINTAINER charles@charlesreid1.com
|
||||
|
||||
# make mysql data a volume
|
||||
VOLUME ["/var/lib/mysql"]
|
||||
|
||||
# put password in a password file
|
||||
RUN printf "[client]\nuser: root\npassword: $MYSQL_ROOT_PASSWORD" > /etc/mysql/conf.d/rootpw.cnf
|
||||
RUN chmod 0600 /etc/mysql/conf.d/rootpw.cnf
|
||||
RUN printf "[client]\nuser=root\npassword=$MYSQL_ROOT_PASSWORD" > /root/.mysql.rootpw.cnf
|
||||
RUN chmod 0600 /root/.mysql.rootpw.cnf
|
||||
|
||||
RUN chown mysql:mysql /var/lib/mysql
|
||||
|
Reference in New Issue
Block a user