Skip to content

Update shebang and error handling in entrypoint and healthcheck scripts #642

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: next
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion 10.11-ubi/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 10.11-ubi/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 10.11/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 10.11/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 10.5/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 10.5/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 10.6-ubi/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 10.6-ubi/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 10.6/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 10.6/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 11.4-ubi/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 11.4-ubi/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion 11.4/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion 11.4/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
10 changes: 5 additions & 5 deletions 11.7-ubi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ COPY MariaDB.repo /etc/yum.repos.d/
# https://access.redhat.com/documentation/en-us/red_hat_software_certification/2024/html/red_hat_openshift_software_certification_policy_guide/assembly-requirements-for-container-images_openshift-sw-cert-policy-introduction#con-image-metadata-requirements_openshift-sw-cert-policy-container-images
LABEL name="MariaDB Server" \
vendor="MariaDB Community" \
version="11.7.1" \
version="11.7.2" \
release="Refer to Annotations org.opencontainers.image.{revision,source}" \
summary="MariaDB Database" \
description="MariaDB Database for relational SQL"
Expand All @@ -50,13 +50,13 @@ LABEL org.opencontainers.image.authors="MariaDB Community" \
org.opencontainers.image.licenses="GPL-2.0" \
org.opencontainers.image.source="https://github.com/MariaDB/mariadb-docker" \
org.opencontainers.image.vendor="MariaDB Community" \
org.opencontainers.image.version="11.7.1" \
org.opencontainers.image.version="11.7.2" \
org.opencontainers.image.url="https://github.com/MariaDB/mariadb-docker"

# bashbrew-architectures: amd64 arm64v8 ppc64le s390x
ARG MARIADB_VERSION=11.7.1
ARG MARIADB_VERSION=11.7.2
ENV MARIADB_VERSION=$MARIADB_VERSION
# release-status:RC
# release-status:Stable
# release-support-type:Short Term Support
# (https://downloads.mariadb.org/rest-api/mariadb/)

Expand All @@ -83,7 +83,7 @@ RUN set -eux ; \
unset GNUPGHOME ; \
microdnf update -y ; \
microdnf reinstall -y tzdata ; \
microdnf install -y procps-ng zstd xz jemalloc pwgen pv ; \
microdnf install -y procps-ng zstd xz jemalloc pwgen pv util-linux-core ; \
mkdir -p /etc/mysql/conf.d /etc/mysql/mariadb.conf.d/ /var/lib/mysql/mysql /run/mariadb /usr/lib64/galera ; \
chmod ugo+rwx,o+t /run/mariadb ; \
microdnf install -y MariaDB-backup-${MARIADB_VERSION} MariaDB-server-${MARIADB_VERSION} ; \
Expand Down
5 changes: 3 additions & 2 deletions 11.7-ubi/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down Expand Up @@ -225,7 +226,7 @@ docker_create_db_directories() {
}

_mariadb_version() {
echo -n "11.7.1-MariaDB"
echo -n "11.7.2-MariaDB"
}

# initializes the database directory
Expand Down
2 changes: 1 addition & 1 deletion 11.7-ubi/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
8 changes: 4 additions & 4 deletions 11.7/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,18 @@ LABEL org.opencontainers.image.authors="MariaDB Community" \
org.opencontainers.image.licenses="GPL-2.0" \
org.opencontainers.image.source="https://github.com/MariaDB/mariadb-docker" \
org.opencontainers.image.vendor="MariaDB Community" \
org.opencontainers.image.version="11.7.1" \
org.opencontainers.image.version="11.7.2" \
org.opencontainers.image.url="https://github.com/MariaDB/mariadb-docker"

# bashbrew-architectures: amd64 arm64v8 ppc64le s390x
ARG MARIADB_VERSION=1:11.7.1+maria~ubu2404
ARG MARIADB_VERSION=1:11.7.2+maria~ubu2404
ENV MARIADB_VERSION $MARIADB_VERSION
# release-status:RC
# release-status:Stable
# release-support-type:Short Term Support
# (https://downloads.mariadb.org/rest-api/mariadb/)

# Allowing overriding of REPOSITORY, a URL that includes suite and component for testing and Enterprise Versions
ARG REPOSITORY="http://archive.mariadb.org/mariadb-11.7.1/repo/ubuntu/ noble main main/debug"
ARG REPOSITORY="http://archive.mariadb.org/mariadb-11.7.2/repo/ubuntu/ noble main main/debug"

RUN set -e;\
echo "deb ${REPOSITORY}" > /etc/apt/sources.list.d/mariadb.list; \
Expand Down
5 changes: 3 additions & 2 deletions 11.7/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down Expand Up @@ -225,7 +226,7 @@ docker_create_db_directories() {
}

_mariadb_version() {
echo -n "11.7.1-MariaDB"
echo -n "11.7.2-MariaDB"
}

# initializes the database directory
Expand Down
2 changes: 1 addition & 1 deletion 11.7/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
12 changes: 6 additions & 6 deletions 11.6-ubi/Dockerfile → 11.8-ubi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ COPY MariaDB.repo /etc/yum.repos.d/
# https://access.redhat.com/documentation/en-us/red_hat_software_certification/2024/html/red_hat_openshift_software_certification_policy_guide/assembly-requirements-for-container-images_openshift-sw-cert-policy-introduction#con-image-metadata-requirements_openshift-sw-cert-policy-container-images
LABEL name="MariaDB Server" \
vendor="MariaDB Community" \
version="11.6.2" \
version="11.8.1" \
release="Refer to Annotations org.opencontainers.image.{revision,source}" \
summary="MariaDB Database" \
description="MariaDB Database for relational SQL"
Expand All @@ -50,14 +50,14 @@ LABEL org.opencontainers.image.authors="MariaDB Community" \
org.opencontainers.image.licenses="GPL-2.0" \
org.opencontainers.image.source="https://github.com/MariaDB/mariadb-docker" \
org.opencontainers.image.vendor="MariaDB Community" \
org.opencontainers.image.version="11.6.2" \
org.opencontainers.image.version="11.8.1" \
org.opencontainers.image.url="https://github.com/MariaDB/mariadb-docker"

# bashbrew-architectures: amd64 arm64v8 ppc64le s390x
ARG MARIADB_VERSION=11.6.2
ARG MARIADB_VERSION=11.8.1
ENV MARIADB_VERSION=$MARIADB_VERSION
# release-status:Stable
# release-support-type:Short Term Support
# release-status:RC
# release-support-type:Long Term Support
# (https://downloads.mariadb.org/rest-api/mariadb/)

# missing pwgen(epel), jemalloc(epel) (as entrypoint/user extensions)
Expand All @@ -83,7 +83,7 @@ RUN set -eux ; \
unset GNUPGHOME ; \
microdnf update -y ; \
microdnf reinstall -y tzdata ; \
microdnf install -y procps-ng zstd xz jemalloc pwgen pv ; \
microdnf install -y procps-ng zstd xz jemalloc pwgen pv util-linux-core ; \
mkdir -p /etc/mysql/conf.d /etc/mysql/mariadb.conf.d/ /var/lib/mysql/mysql /run/mariadb /usr/lib64/galera ; \
chmod ugo+rwx,o+t /run/mariadb ; \
microdnf install -y MariaDB-backup-${MARIADB_VERSION} MariaDB-server-${MARIADB_VERSION} ; \
Expand Down
4 changes: 2 additions & 2 deletions 11.6-ubi/MariaDB.repo → 11.8-ubi/MariaDB.repo
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[mariadb]
name = MariaDB
#baseurl = https://rpm.mariadb.org/11.6/rhel/$releasever/$basearch
baseurl = https://archive.mariadb.org/mariadb-11.6/yum/rhel/$releasever/$basearch
#baseurl = https://rpm.mariadb.org/11.8/rhel/$releasever/$basearch
baseurl = https://archive.mariadb.org/mariadb-11.8/yum/rhel/$releasever/$basearch
#microdnf cannot read to the second key here.
#gpgkey=https://archive.mariadb.org/PublicKey
gpgcheck=1
5 changes: 3 additions & 2 deletions 11.6/docker-entrypoint.sh → 11.8-ubi/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down Expand Up @@ -225,7 +226,7 @@ docker_create_db_directories() {
}

_mariadb_version() {
echo -n "11.6.2-MariaDB"
echo -n "11.8.1-MariaDB"
}

# initializes the database directory
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion 11.6/healthcheck.sh → 11.8-ubi/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
10 changes: 5 additions & 5 deletions 11.6/Dockerfile → 11.8/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,18 @@ LABEL org.opencontainers.image.authors="MariaDB Community" \
org.opencontainers.image.licenses="GPL-2.0" \
org.opencontainers.image.source="https://github.com/MariaDB/mariadb-docker" \
org.opencontainers.image.vendor="MariaDB Community" \
org.opencontainers.image.version="11.6.2" \
org.opencontainers.image.version="11.8.1" \
org.opencontainers.image.url="https://github.com/MariaDB/mariadb-docker"

# bashbrew-architectures: amd64 arm64v8 ppc64le s390x
ARG MARIADB_VERSION=1:11.6.2+maria~ubu2404
ARG MARIADB_VERSION=1:11.8.1+maria~ubu2404
ENV MARIADB_VERSION $MARIADB_VERSION
# release-status:Stable
# release-support-type:Short Term Support
# release-status:RC
# release-support-type:Long Term Support
# (https://downloads.mariadb.org/rest-api/mariadb/)

# Allowing overriding of REPOSITORY, a URL that includes suite and component for testing and Enterprise Versions
ARG REPOSITORY="http://archive.mariadb.org/mariadb-11.6.2/repo/ubuntu/ noble main main/debug"
ARG REPOSITORY="http://archive.mariadb.org/mariadb-11.8.1/repo/ubuntu/ noble main main/debug"

RUN set -e;\
echo "deb ${REPOSITORY}" > /etc/apt/sources.list.d/mariadb.list; \
Expand Down
5 changes: 3 additions & 2 deletions 11.6-ubi/docker-entrypoint.sh → 11.8/docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down Expand Up @@ -225,7 +226,7 @@ docker_create_db_directories() {
}

_mariadb_version() {
echo -n "11.6.2-MariaDB"
echo -n "11.8.1-MariaDB"
}

# initializes the database directory
Expand Down
2 changes: 1 addition & 1 deletion 11.6-ubi/healthcheck.sh → 11.8/healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
3 changes: 2 additions & 1 deletion docker-entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#!/bin/bash
set -eo pipefail

set -Eeuo pipefail
shopt -s nullglob

# logging functions
Expand Down
2 changes: 1 addition & 1 deletion healthcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
# Note * though denied error message will result in error log without
# any permissions. USAGE recommend to avoid this.

set -eo pipefail
set -Eeuo pipefail

_process_sql()
{
Expand Down
6 changes: 3 additions & 3 deletions main-ubi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ COPY MariaDB.repo /etc/yum.repos.d/
# https://access.redhat.com/documentation/en-us/red_hat_software_certification/2024/html/red_hat_openshift_software_certification_policy_guide/assembly-requirements-for-container-images_openshift-sw-cert-policy-introduction#con-image-metadata-requirements_openshift-sw-cert-policy-container-images
LABEL name="MariaDB Server" \
vendor="MariaDB Community" \
version="11.8.0" \
version="12.0.0" \
release="Refer to Annotations org.opencontainers.image.{revision,source}" \
summary="MariaDB Database" \
description="MariaDB Database for relational SQL"
Expand All @@ -50,11 +50,11 @@ LABEL org.opencontainers.image.authors="MariaDB Community" \
org.opencontainers.image.licenses="GPL-2.0" \
org.opencontainers.image.source="https://github.com/MariaDB/mariadb-docker" \
org.opencontainers.image.vendor="MariaDB Community" \
org.opencontainers.image.version="11.8.0" \
org.opencontainers.image.version="12.0.0" \
org.opencontainers.image.url="https://github.com/MariaDB/mariadb-docker"

# bashbrew-architectures: amd64 arm64v8 ppc64le s390x
ARG MARIADB_VERSION=11.8.0
ARG MARIADB_VERSION=12.0.0
ENV MARIADB_VERSION=$MARIADB_VERSION
# release-status:Alpha
# release-support-type:Unknown
Expand Down
Loading