-
-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathpercona-5.7
More file actions
25 lines (23 loc) · 737 Bytes
/
percona-5.7
File metadata and controls
25 lines (23 loc) · 737 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# vi: ft=dockerfile
FROM percona:5.7
USER root
RUN set -eux \
&& mkdir -p /etc/mysql/docker-default.d/ \
&& if [ -f /etc/my.cnf ]; then \
echo '!'"includedir /etc/mysql/docker-default.d/" >> /etc/my.cnf; \
elif [ -f /etc/mysql/my.cnf ]; then \
echo '!'"includedir /etc/mysql/docker-default.d/" >> /etc/mysql/my.cnf; \
else \
echo "/etc/my.cnf and /etc/mysql/my.cnf are not available"; \
false; \
fi \
&& if [ -f "/entrypoint.sh" ]; then \
mv "/entrypoint.sh" "/docker-entrypoint.sh"; \
fi \
&& if [ ! -f "/docker-entrypoint.sh" ]; then \
ln -s "/usr/local/bin/docker-entrypoint.sh" "/docker-entrypoint.sh"; \
fi \
&& chmod +x "/docker-entrypoint.sh"
USER mysql
ENTRYPOINT ["/docker-entrypoint.sh"]
CMD ["mysqld"]