2020-06-21 08:39:38 +02:00
|
|
|
IMAGE mariadb_10.4.13-200621
|
2020-06-21 08:26:58 +02:00
|
|
|
FROM alpine3.11_3.11.6-200621
|
2018-09-13 13:27:09 +02:00
|
|
|
|
|
|
|
RUN EOF
|
|
|
|
# Create OS user (which will be picked up later by apk add)
|
|
|
|
addgroup -S -g 3306 mysql
|
|
|
|
adduser -S -u 3306 -h /var/lib/mysql -s /bin/false -g mysql -G mysql mysql
|
|
|
|
|
|
|
|
# Install MariaDB
|
|
|
|
apk --no-cache add mariadb mariadb-client
|
|
|
|
|
|
|
|
# Create socket directory
|
|
|
|
mkdir /run/mysqld
|
|
|
|
chown mysql:mysql /run/mysqld
|
|
|
|
EOF
|
|
|
|
|
2020-03-18 22:54:40 +01:00
|
|
|
# Due to MySQL's socket authentication design the container init needs to be run as root
|
|
|
|
COPY image.d
|
|
|
|
|
|
|
|
CMD /bin/s6-svscan /etc/services.d
|
2020-03-19 22:36:59 +01:00
|
|
|
READY /usr/bin/test -e /run/mysqld/mysqld.sock
|
2018-09-20 07:21:24 +02:00
|
|
|
HALT SIGTERM
|