Skip to content

Commit

Permalink
Merge pull request #728 from cybozu-go/rebuild-mysql
Browse files Browse the repository at this point in the history
rebuild mysql image and add mysqld 8.0.39, 8.4.2
  • Loading branch information
YZ775 committed Sep 11, 2024
2 parents f25abd4 + 5cc9cf5 commit 315ca63
Show file tree
Hide file tree
Showing 22 changed files with 128 additions and 14 deletions.
2 changes: 1 addition & 1 deletion containers/mysql/8.0.18/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.18.11
8.0.18.12
2 changes: 1 addition & 1 deletion containers/mysql/8.0.25/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.25.11
8.0.25.12
2 changes: 1 addition & 1 deletion containers/mysql/8.0.26/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.26.12
8.0.26.13
2 changes: 1 addition & 1 deletion containers/mysql/8.0.27/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.27.10
8.0.27.11
2 changes: 1 addition & 1 deletion containers/mysql/8.0.28/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.28.12
8.0.28.13
2 changes: 1 addition & 1 deletion containers/mysql/8.0.30/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.30.10
8.0.30.11
2 changes: 1 addition & 1 deletion containers/mysql/8.0.31/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.31.9
8.0.31.10
2 changes: 1 addition & 1 deletion containers/mysql/8.0.32/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.32.4
8.0.32.5
2 changes: 1 addition & 1 deletion containers/mysql/8.0.33/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.33.3
8.0.33.4
2 changes: 1 addition & 1 deletion containers/mysql/8.0.34/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.34.3
8.0.34.4
2 changes: 1 addition & 1 deletion containers/mysql/8.0.35/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.35.2
8.0.35.3
2 changes: 1 addition & 1 deletion containers/mysql/8.0.36/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.36.2
8.0.36.3
2 changes: 1 addition & 1 deletion containers/mysql/8.0.37/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.0.37.1
8.0.37.2
1 change: 1 addition & 0 deletions containers/mysql/8.0.39/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*
40 changes: 40 additions & 0 deletions containers/mysql/8.0.39/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
FROM ghcr.io/cybozu/ubuntu-dev:22.04 AS builder

ARG MYSQL_VERSION=8.0.39

RUN apt-get update && apt-get -y install --no-install-recommends \
cmake \
libncurses5-dev \
libjemalloc-dev \
libnuma-dev \
libaio-dev \
pkg-config

RUN cd tmp/ \
&& curl -fsSL -O https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-boost-${MYSQL_VERSION}.tar.gz \
&& tar -x -z -f mysql-boost-${MYSQL_VERSION}.tar.gz \
&& cd mysql-${MYSQL_VERSION} \
&& mkdir bld \
&& cd bld \
&& cmake .. -DBUILD_CONFIG=mysql_release -DCMAKE_BUILD_TYPE=Release -DWITH_BOOST=$(ls -d ../boost/boost_*) -DWITH_NUMA=1 -DWITH_JEMALLOC=1 -DWITH_PACKAGE_FLAGS=0 \
&& make -j 20 \
&& make install

FROM ghcr.io/cybozu/ubuntu:22.04

COPY --from=builder /usr/local/mysql/LICENSE /usr/local/mysql/LICENSE
COPY --from=builder /usr/local/mysql/bin /usr/local/mysql/bin
COPY --from=builder /usr/local/mysql/lib /usr/local/mysql/lib
COPY --from=builder /usr/local/mysql/share /usr/local/mysql/share

RUN apt-get update \
&& apt-get install -y --no-install-recommends libjemalloc2 libnuma1 libaio1 \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p /var/lib/mysql \
&& chown -R 10000:10000 /var/lib/mysql

ENV PATH=/usr/local/mysql/bin:"$PATH"
VOLUME /var/lib/mysql
ENTRYPOINT ["mysqld"]
EXPOSE 3306 33060 33062 8080
USER 10000:10000
1 change: 1 addition & 0 deletions containers/mysql/8.0.39/TAG
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8.0.39.1
15 changes: 15 additions & 0 deletions containers/mysql/8.0.39/container-structure-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
schemaVersion: '2.0.0'
fileExistenceTests:
- name: 'mysqld'
path: '/usr/local/mysql/bin/mysqld'
shouldExist: true
isExecutableBy: 'owner'
- name: 'mysql lib'
path: '/usr/local/mysql/lib'
shouldExist: true
- name: 'mysql share'
path: '/usr/local/mysql/share'
shouldExist: true
- name: 'mysql LICENSE'
path: '/usr/local/mysql/LICENSE'
shouldExist: true
2 changes: 1 addition & 1 deletion containers/mysql/8.4.0/TAG
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.4.0.1
8.4.0.2
1 change: 1 addition & 0 deletions containers/mysql/8.4.2/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*
40 changes: 40 additions & 0 deletions containers/mysql/8.4.2/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
FROM ghcr.io/cybozu/ubuntu-dev:22.04 AS builder

ARG MYSQL_VERSION=8.4.2

RUN apt-get update && apt-get -y install --no-install-recommends \
cmake \
libncurses5-dev \
libjemalloc-dev \
libnuma-dev \
libaio-dev \
pkg-config

RUN cd tmp/ \
&& curl -fsSL -O https://dev.mysql.com/get/Downloads/MySQL-8.4/mysql-${MYSQL_VERSION}.tar.gz \
&& tar -x -z -f mysql-${MYSQL_VERSION}.tar.gz \
&& cd mysql-${MYSQL_VERSION} \
&& mkdir bld \
&& cd bld \
&& cmake .. -DBUILD_CONFIG=mysql_release -DCMAKE_BUILD_TYPE=Release -DWITH_NUMA=1 -DWITH_JEMALLOC=1 -DWITH_PACKAGE_FLAGS=0 \
&& make -j 20 \
&& make install

FROM ghcr.io/cybozu/ubuntu:22.04

COPY --from=builder /usr/local/mysql/LICENSE /usr/local/mysql/LICENSE
COPY --from=builder /usr/local/mysql/bin /usr/local/mysql/bin
COPY --from=builder /usr/local/mysql/lib /usr/local/mysql/lib
COPY --from=builder /usr/local/mysql/share /usr/local/mysql/share

RUN apt-get update \
&& apt-get install -y --no-install-recommends libjemalloc2 libnuma1 libaio1 \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p /var/lib/mysql \
&& chown -R 10000:10000 /var/lib/mysql

ENV PATH=/usr/local/mysql/bin:"$PATH"
VOLUME /var/lib/mysql
ENTRYPOINT ["mysqld"]
EXPOSE 3306 33060 33062 8080
USER 10000:10000
1 change: 1 addition & 0 deletions containers/mysql/8.4.2/TAG
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8.4.2.1
15 changes: 15 additions & 0 deletions containers/mysql/8.4.2/container-structure-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
schemaVersion: '2.0.0'
fileExistenceTests:
- name: 'mysqld'
path: '/usr/local/mysql/bin/mysqld'
shouldExist: true
isExecutableBy: 'owner'
- name: 'mysql lib'
path: '/usr/local/mysql/lib'
shouldExist: true
- name: 'mysql share'
path: '/usr/local/mysql/share'
shouldExist: true
- name: 'mysql LICENSE'
path: '/usr/local/mysql/LICENSE'
shouldExist: true

0 comments on commit 315ca63

Please sign in to comment.