1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-12-14 11:23:34 +02:00
dockerfiles/mariadb/Dockerfile

26 lines
581 B
Docker
Raw Normal View History

2016-03-06 16:45:23 +02:00
#
# Dockerfile for mariadb
#
FROM alpine
2016-05-01 03:06:20 +02:00
MAINTAINER kev <noreplay@easypi.info>
2016-03-06 16:45:23 +02:00
RUN set -xe \
&& apk add -U bash \
mariadb \
mariadb-client \
tzdata \
&& mkdir -p /run/mysqld \
&& chown mysql:mysql /run/mysqld \
&& sed -Ei -e 's/^(bind-address|log)/#&/' \
-e 's/^\[mysqld\]$/&\nskip-host-cache\nskip-name-resolve\nuser=mysql/' /etc/mysql/my.cnf \
&& rm -rf /var/cache/apk/*
COPY docker-entrypoint.sh /
VOLUME /var/lib/mysql
ENTRYPOINT ["/docker-entrypoint.sh"]
EXPOSE 3306
CMD ["mysqld"]