Skip to content

Commit

Permalink
Merge pull request #15 from devilbox/release-0.13
Browse files Browse the repository at this point in the history
Add arm64 for MySQL 8.0
  • Loading branch information
cytopia authored Mar 6, 2022
2 parents 91e4663 + b359198 commit 8331749
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 6 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/params.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,14 @@ env:
[
{
"NAME": "mysql",
"VERSION": ["5.5", "5.6", "5.7", "8.0"],
"VERSION": ["5.5", "5.6", "5.7"],
"ARCH": ["linux/amd64"]
},
{
"NAME": "mysql",
"VERSION": ["8.0"],
"ARCH": ["linux/amd64", "linux/arm64"]
},
{
"NAME": "mariadb",
"VERSION": ["5.5", "10.0"],
Expand Down
21 changes: 17 additions & 4 deletions Dockerfiles/mysql-8.0
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# vi: ft=dockerfile
FROM mysql:8.0
FROM mysql:8.0-oracle

RUN set -eux \
# Set Additional config directories
&& mkdir -p /etc/mysql/docker-default.d/ \
&& if [ -f /etc/my.cnf ]; then \
echo '!'"includedir /etc/mysql/docker-default.d/" >> /etc/my.cnf; \
Expand All @@ -11,13 +12,25 @@ RUN set -eux \
echo "/etc/my.cnf and /etc/mysql/my.cnf are not available"; \
false; \
fi \
\
# Allow native password handling for MySQL 8.0
&& sed -i'' 's/^\[mysqld\]/[mysqld]\ndefault-authentication-plugin=mysql_native_password/g' /etc/mysql/my.cnf \
&& if [ -f /etc/my.cnf ]; then \
sed -i'' 's/^\[mysqld\]/[mysqld]\ndefault-authentication-plugin=mysql_native_password/g' /etc/my.cnf; \
elif [ -f /etc/mysql/my.cnf ]; then \
sed -i'' 's/^\[mysqld\]/[mysqld]\ndefault-authentication-plugin=mysql_native_password/g' /etc/mysql/my.cnf; \
else \
echo "/etc/my.cnf and /etc/mysql/my.cnf are not available"; \
false; \
fi \
\
# Set Docker Entrypoint
&& if [ -f "/entrypoint.sh" ]; then \
mv "/entrypoint.sh" "/docker-entrypoint.sh"; \
fi \
&& if [ ! -f "/docker-entrypoint.sh" ]; then \
elif [ -f "/usr/local/bin/docker-entrypoint.sh" ]; then \
ln -s "/usr/local/bin/docker-entrypoint.sh" "/docker-entrypoint.sh"; \
else \
echo "/entrypoint.sh and /usr/local/bin/docker-entrypoint.sh are not available"; \
false; \
fi \
&& chmod +x "/docker-entrypoint.sh"

Expand Down
2 changes: 1 addition & 1 deletion tests/02-mysqli.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ run "docker run -d --rm --platform ${ARCH} $(tty -s && echo "-it" || echo) --hos

# Pull PHP image
echo "2/5 Pulling PHP image "
while ! run "docker pull php:7.2"; do
while ! run "docker pull --platform ${ARCH} php:7.2"; do
sleep 1
done

Expand Down

0 comments on commit 8331749

Please sign in to comment.