From 1452dabe225f673d2d1fabbd6384ce707e2f5d36 Mon Sep 17 00:00:00 2001 From: Toby Bellwood Date: Tue, 8 Oct 2024 16:56:46 +1100 Subject: [PATCH] build: replace upstream tini with krallin/tini Co-authored-by: Nick Dickinson Wilde --- images/mysql/8.0.Dockerfile | 6 ++++-- images/mysql/8.4.Dockerfile | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/images/mysql/8.0.Dockerfile b/images/mysql/8.0.Dockerfile index 6f6f92d2a..847c07354 100644 --- a/images/mysql/8.0.Dockerfile +++ b/images/mysql/8.0.Dockerfile @@ -44,11 +44,13 @@ RUN microdnf install -y epel-release \ gettext \ net-tools \ pwgen \ - tini \ wget; \ rm -rf /var/lib/mysql/* /etc/mysql/ /etc/my.cnf*; \ curl -sSL https://raw.githubusercontent.com/major/MySQLTuner-perl/master/mysqltuner.pl -o mysqltuner.pl +RUN architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \ + && curl -sL https://github.com/krallin/tini/releases/download/v0.19.0/tini-${architecture} -o /sbin/tini && chmod a+x /sbin/tini + COPY entrypoints/ /lagoon/entrypoints/ COPY mysql-backup.sh /lagoon/ COPY my.cnf /etc/mysql/my.cnf @@ -73,5 +75,5 @@ ENV USER_NAME=mysql WORKDIR /var/lib/mysql EXPOSE 3306 -ENTRYPOINT ["/usr/bin/tini", "--", "/lagoon/entrypoints.bash"] +ENTRYPOINT ["/sbin/tini", "--", "/lagoon/entrypoints.bash"] CMD ["mysqld"] diff --git a/images/mysql/8.4.Dockerfile b/images/mysql/8.4.Dockerfile index 620ade743..481b214cf 100644 --- a/images/mysql/8.4.Dockerfile +++ b/images/mysql/8.4.Dockerfile @@ -43,11 +43,13 @@ RUN microdnf install -y epel-release \ gettext \ net-tools \ pwgen \ - tini \ wget; \ rm -rf /var/lib/mysql/* /etc/mysql/ /etc/my.cnf*; \ curl -sSL https://raw.githubusercontent.com/major/MySQLTuner-perl/master/mysqltuner.pl -o mysqltuner.pl +RUN architecture=$(case $(uname -m) in x86_64 | amd64) echo "amd64" ;; aarch64 | arm64 | armv8) echo "arm64" ;; *) echo "amd64" ;; esac) \ + && curl -sL https://github.com/krallin/tini/releases/download/v0.19.0/tini-${architecture} -o /sbin/tini && chmod a+x /sbin/tini + COPY entrypoints/ /lagoon/entrypoints/ COPY mysql-backup.sh /lagoon/ COPY my.cnf /etc/mysql/my.cnf @@ -72,5 +74,5 @@ ENV USER_NAME=mysql WORKDIR /var/lib/mysql EXPOSE 3306 -ENTRYPOINT ["/usr/bin/tini", "--", "/lagoon/entrypoints.bash"] +ENTRYPOINT ["/sbin/tini", "--", "/lagoon/entrypoints.bash"] CMD ["mysqld"]