From ba0e04a5972e118092f4a68f4934f512dd09ac54 Mon Sep 17 00:00:00 2001 From: Alexey Pustovalov Date: Fri, 22 Mar 2024 14:53:18 +0900 Subject: [PATCH] Added tzdata package for most of images --- Dockerfiles/agent/centos/Dockerfile | 8 +++++++- Dockerfiles/agent2/alpine/Dockerfile | 4 ++-- Dockerfiles/agent2/centos/Dockerfile | 8 +++++++- Dockerfiles/proxy-mysql/alpine/Dockerfile | 1 + Dockerfiles/proxy-mysql/centos/Dockerfile | 7 +++++++ Dockerfiles/proxy-mysql/ubuntu/Dockerfile | 1 + Dockerfiles/proxy-sqlite3/alpine/Dockerfile | 1 + Dockerfiles/proxy-sqlite3/centos/Dockerfile | 10 +++++++++- Dockerfiles/proxy-sqlite3/ubuntu/Dockerfile | 1 + Dockerfiles/server-mysql/centos/Dockerfile | 8 +++++++- Dockerfiles/server-pgsql/centos/Dockerfile | 8 +++++++- Dockerfiles/web-apache-mysql/alpine/Dockerfile | 1 + Dockerfiles/web-apache-mysql/centos/Dockerfile | 2 +- Dockerfiles/web-apache-mysql/ubuntu/Dockerfile | 1 + Dockerfiles/web-apache-pgsql/alpine/Dockerfile | 1 + Dockerfiles/web-apache-pgsql/ubuntu/Dockerfile | 1 + Dockerfiles/web-nginx-mysql/alpine/Dockerfile | 1 + Dockerfiles/web-nginx-mysql/ubuntu/Dockerfile | 1 + Dockerfiles/web-nginx-pgsql/alpine/Dockerfile | 1 + Dockerfiles/web-nginx-pgsql/ubuntu/Dockerfile | 1 + 20 files changed, 59 insertions(+), 8 deletions(-) diff --git a/Dockerfiles/agent/centos/Dockerfile b/Dockerfiles/agent/centos/Dockerfile index 1ae719dcb..eee87e086 100644 --- a/Dockerfiles/agent/centos/Dockerfile +++ b/Dockerfiles/agent/centos/Dockerfile @@ -34,7 +34,6 @@ COPY --from=builder ["/tmp/zabbix-${ZBX_VERSION}/conf/zabbix_agentd.conf", "/etc RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ set -eux && \ INSTALL_PKGS="bash \ - tzdata \ iputils \ pcre2 \ libcurl-minimal \ @@ -58,6 +57,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ groupadd \ --system \ --gid 1995 \ diff --git a/Dockerfiles/agent2/alpine/Dockerfile b/Dockerfiles/agent2/alpine/Dockerfile index f9cf50178..4dbe97ab7 100644 --- a/Dockerfiles/agent2/alpine/Dockerfile +++ b/Dockerfiles/agent2/alpine/Dockerfile @@ -37,8 +37,8 @@ COPY --from=builder ["/tmp/mongodb_plugin/zabbix-agent2-plugin-mongodb", "/usr/s COPY --from=builder ["/tmp/postgresql_plugin/zabbix-agent2-plugin-postgresql", "/usr/sbin/zabbix-agent2-plugin/zabbix-agent2-plugin-postgresql"] RUN set -eux && \ - INSTALL_PKGS="tzdata \ - bash \ + INSTALL_PKGS="bash \ + tzdata \ pcre2 \ coreutils \ smartmontools \ diff --git a/Dockerfiles/agent2/centos/Dockerfile b/Dockerfiles/agent2/centos/Dockerfile index cf4314820..92f614eb0 100644 --- a/Dockerfiles/agent2/centos/Dockerfile +++ b/Dockerfiles/agent2/centos/Dockerfile @@ -39,7 +39,6 @@ COPY --from=builder ["/tmp/postgresql_plugin/zabbix-agent2-plugin-postgresql", " RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ set -eux && \ INSTALL_PKGS="bash \ - tzdata \ iputils \ pcre2 \ libcurl-minimal \ @@ -63,6 +62,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ groupadd \ --system \ --gid 1995 \ diff --git a/Dockerfiles/proxy-mysql/alpine/Dockerfile b/Dockerfiles/proxy-mysql/alpine/Dockerfile index 9beabbafc..bd44c297e 100644 --- a/Dockerfiles/proxy-mysql/alpine/Dockerfile +++ b/Dockerfiles/proxy-mysql/alpine/Dockerfile @@ -36,6 +36,7 @@ COPY --from=builder ["/tmp/zabbix-${ZBX_VERSION}/database/mysql/create_proxy.sql RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ traceroute \ nmap \ iputils \ diff --git a/Dockerfiles/proxy-mysql/centos/Dockerfile b/Dockerfiles/proxy-mysql/centos/Dockerfile index 68911ab87..557a11754 100644 --- a/Dockerfiles/proxy-mysql/centos/Dockerfile +++ b/Dockerfiles/proxy-mysql/centos/Dockerfile @@ -71,6 +71,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ groupadd \ --system \ --gid 1995 \ diff --git a/Dockerfiles/proxy-mysql/ubuntu/Dockerfile b/Dockerfiles/proxy-mysql/ubuntu/Dockerfile index 944330b2b..6383b7a98 100644 --- a/Dockerfiles/proxy-mysql/ubuntu/Dockerfile +++ b/Dockerfiles/proxy-mysql/ubuntu/Dockerfile @@ -39,6 +39,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ traceroute \ nmap \ ca-certificates \ diff --git a/Dockerfiles/proxy-sqlite3/alpine/Dockerfile b/Dockerfiles/proxy-sqlite3/alpine/Dockerfile index eb8960bec..d58c0d77d 100644 --- a/Dockerfiles/proxy-sqlite3/alpine/Dockerfile +++ b/Dockerfiles/proxy-sqlite3/alpine/Dockerfile @@ -35,6 +35,7 @@ COPY --from=builder ["/tmp/zabbix-${ZBX_VERSION}/conf/zabbix_proxy.conf", "/etc/ RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ traceroute \ nmap \ fping \ diff --git a/Dockerfiles/proxy-sqlite3/centos/Dockerfile b/Dockerfiles/proxy-sqlite3/centos/Dockerfile index c3bb970af..0dc7e6c33 100644 --- a/Dockerfiles/proxy-sqlite3/centos/Dockerfile +++ b/Dockerfiles/proxy-sqlite3/centos/Dockerfile @@ -35,7 +35,8 @@ COPY --from=builder ["/tmp/zabbix-${ZBX_VERSION}/conf/zabbix_proxy.conf", "/etc/ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ set -eux && \ - INSTALL_PKGS="libevent \ + INSTALL_PKGS="bash \ + libevent \ traceroute \ nmap \ libssh \ @@ -66,6 +67,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ groupadd \ --system \ --gid 1995 \ diff --git a/Dockerfiles/proxy-sqlite3/ubuntu/Dockerfile b/Dockerfiles/proxy-sqlite3/ubuntu/Dockerfile index 56bc256e3..3e9c16d14 100644 --- a/Dockerfiles/proxy-sqlite3/ubuntu/Dockerfile +++ b/Dockerfiles/proxy-sqlite3/ubuntu/Dockerfile @@ -37,6 +37,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ traceroute \ nmap \ ca-certificates \ diff --git a/Dockerfiles/server-mysql/centos/Dockerfile b/Dockerfiles/server-mysql/centos/Dockerfile index 775791b91..5fecd84a5 100644 --- a/Dockerfiles/server-mysql/centos/Dockerfile +++ b/Dockerfiles/server-mysql/centos/Dockerfile @@ -40,7 +40,6 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ traceroute \ nmap \ file-libs \ - tzdata \ iputils \ traceroute \ libpsl \ @@ -78,6 +77,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ microdnf download libcurl && \ rpm -Uvh --nodeps --replacefiles "*curl*$( uname -i ).rpm" && \ microdnf remove -y libcurl-minimal && \ diff --git a/Dockerfiles/server-pgsql/centos/Dockerfile b/Dockerfiles/server-pgsql/centos/Dockerfile index 581428bde..9ef6a9c37 100644 --- a/Dockerfiles/server-pgsql/centos/Dockerfile +++ b/Dockerfiles/server-pgsql/centos/Dockerfile @@ -44,7 +44,6 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ traceroute \ nmap \ iputils \ - tzdata \ traceroute \ libevent \ libssh \ @@ -78,6 +77,13 @@ RUN --mount=type=tmpfs,target=/var/lib/dnf/ \ --setopt=keepcache=0 \ --best \ --nodocs ${INSTALL_PKGS} && \ + microdnf -y reinstall \ + --enablerepo "baseos" \ + --setopt=install_weak_deps=0 \ + --setopt=keepcache=0 \ + --best \ + --setopt=tsflags=nodocs \ + tzdata && \ microdnf download libcurl && \ rpm -Uvh --nodeps --replacefiles "*curl*$( uname -i ).rpm" && \ microdnf remove -y libcurl-minimal && \ diff --git a/Dockerfiles/web-apache-mysql/alpine/Dockerfile b/Dockerfiles/web-apache-mysql/alpine/Dockerfile index f2a6caa1f..adc68427b 100644 --- a/Dockerfiles/web-apache-mysql/alpine/Dockerfile +++ b/Dockerfiles/web-apache-mysql/alpine/Dockerfile @@ -31,6 +31,7 @@ COPY ["conf/etc/", "/etc/"] RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ apache2 \ curl \ mariadb-client \ diff --git a/Dockerfiles/web-apache-mysql/centos/Dockerfile b/Dockerfiles/web-apache-mysql/centos/Dockerfile index 9e3e4845a..a948399f6 100644 --- a/Dockerfiles/web-apache-mysql/centos/Dockerfile +++ b/Dockerfiles/web-apache-mysql/centos/Dockerfile @@ -1,4 +1,4 @@ -# syntax=docker/dockerfile:1 +# syntax=docker/dockerfile:1c ARG MAJOR_VERSION=7.0 ARG ZBX_VERSION=${MAJOR_VERSION} ARG BUILD_BASE_IMAGE=zabbix-build-mysql:centos-${ZBX_VERSION} diff --git a/Dockerfiles/web-apache-mysql/ubuntu/Dockerfile b/Dockerfiles/web-apache-mysql/ubuntu/Dockerfile index 579a68eff..88cf994d5 100644 --- a/Dockerfiles/web-apache-mysql/ubuntu/Dockerfile +++ b/Dockerfiles/web-apache-mysql/ubuntu/Dockerfile @@ -33,6 +33,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ apache2 \ curl \ libapache2-mod-php \ diff --git a/Dockerfiles/web-apache-pgsql/alpine/Dockerfile b/Dockerfiles/web-apache-pgsql/alpine/Dockerfile index 7a424247b..e18e210cc 100644 --- a/Dockerfiles/web-apache-pgsql/alpine/Dockerfile +++ b/Dockerfiles/web-apache-pgsql/alpine/Dockerfile @@ -31,6 +31,7 @@ COPY ["conf/etc/", "/etc/"] RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ apache2 \ curl \ php83-apache2 \ diff --git a/Dockerfiles/web-apache-pgsql/ubuntu/Dockerfile b/Dockerfiles/web-apache-pgsql/ubuntu/Dockerfile index f658f0955..919b4ff1c 100644 --- a/Dockerfiles/web-apache-pgsql/ubuntu/Dockerfile +++ b/Dockerfiles/web-apache-pgsql/ubuntu/Dockerfile @@ -33,6 +33,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ apache2 \ curl \ libapache2-mod-php \ diff --git a/Dockerfiles/web-nginx-mysql/alpine/Dockerfile b/Dockerfiles/web-nginx-mysql/alpine/Dockerfile index c0b4576a0..807a01687 100644 --- a/Dockerfiles/web-nginx-mysql/alpine/Dockerfile +++ b/Dockerfiles/web-nginx-mysql/alpine/Dockerfile @@ -31,6 +31,7 @@ COPY ["conf/etc/", "/etc/"] RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ curl \ mariadb-client \ mariadb-connector-c \ diff --git a/Dockerfiles/web-nginx-mysql/ubuntu/Dockerfile b/Dockerfiles/web-nginx-mysql/ubuntu/Dockerfile index 6945a089e..021046e19 100644 --- a/Dockerfiles/web-nginx-mysql/ubuntu/Dockerfile +++ b/Dockerfiles/web-nginx-mysql/ubuntu/Dockerfile @@ -33,6 +33,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ ca-certificates \ curl \ mysql-client \ diff --git a/Dockerfiles/web-nginx-pgsql/alpine/Dockerfile b/Dockerfiles/web-nginx-pgsql/alpine/Dockerfile index 245b73566..02a8ccc6e 100644 --- a/Dockerfiles/web-nginx-pgsql/alpine/Dockerfile +++ b/Dockerfiles/web-nginx-pgsql/alpine/Dockerfile @@ -31,6 +31,7 @@ COPY ["conf/etc/", "/etc/"] RUN set -eux && \ INSTALL_PKGS="bash \ + tzdata \ curl \ nginx \ php83-bcmath \ diff --git a/Dockerfiles/web-nginx-pgsql/ubuntu/Dockerfile b/Dockerfiles/web-nginx-pgsql/ubuntu/Dockerfile index 62cac4a6d..1cd076692 100644 --- a/Dockerfiles/web-nginx-pgsql/ubuntu/Dockerfile +++ b/Dockerfiles/web-nginx-pgsql/ubuntu/Dockerfile @@ -33,6 +33,7 @@ RUN --mount=type=cache,target=/var/lib/apt/,sharing=locked \ set -eux && \ echo "#!/bin/sh\nexit 101" > /usr/sbin/policy-rc.d && \ INSTALL_PKGS="bash \ + tzdata \ ca-certificates \ curl \ nginx \