mirror of
https://github.com/zabbix/zabbix-docker.git
synced 2025-08-09 08:35:05 +02:00
Migrastion to GIT
This commit is contained in:
@ -54,9 +54,9 @@ RUN addgroup zabbix && \
|
||||
apk add ${APK_FLAGS_PERSISTENT} --no-scripts apache2-ssl && \
|
||||
rm -rf /var/cache/apk/*
|
||||
|
||||
ARG MAJOR_VERSION=4.0
|
||||
ARG MAJOR_VERSION=4.4
|
||||
ARG ZBX_VERSION=${MAJOR_VERSION}
|
||||
ARG ZBX_SOURCES=svn://svn.zabbix.com/trunk/
|
||||
ARG ZBX_SOURCES=https://git.zabbix.com/scm/zbx/zabbix.git
|
||||
ENV ZBX_VERSION=${ZBX_VERSION} ZBX_SOURCES=${ZBX_SOURCES}
|
||||
|
||||
LABEL org.label-schema.usage="https://www.zabbix.com/documentation/${MAJOR_VERSION}/manual/installation/containers" \
|
||||
@ -68,21 +68,24 @@ COPY ["conf/tmp/font-config", "/tmp/font-config"]
|
||||
|
||||
RUN apk add ${APK_FLAGS_DEV} --virtual build-dependencies \
|
||||
gettext \
|
||||
subversion && \
|
||||
git && \
|
||||
cd /usr/share/ && \
|
||||
svn --quiet export ${ZBX_SOURCES}/frontends/php/ zabbix && \
|
||||
git clone ${ZBX_SOURCES} --branch master --depth 1 --single-branch zabbix-${ZBX_VERSION} && \
|
||||
mkdir /usr/share/zabbix/ && \
|
||||
cp -R /usr/share/zabbix-${ZBX_VERSION}/frontends/php/* /usr/share/zabbix/ && \
|
||||
rm -rf /usr/share/zabbix-${ZBX_VERSION}/ && \
|
||||
cd /usr/share/zabbix/ && \
|
||||
patch -p3 < /tmp/font-config && \
|
||||
rm /tmp/font-config && \
|
||||
rm -f conf/zabbix.conf.php && \
|
||||
rm -rf tests && \
|
||||
rm /usr/share/zabbix/fonts/DejaVuSans.ttf && \
|
||||
rm /usr/share/zabbix/assets/fonts/DejaVuSans.ttf && \
|
||||
./locale/make_mo.sh && \
|
||||
ln -s /usr/share/fonts/ttf-dejavu/DejaVuSans.ttf /usr/share/zabbix/fonts/graphfont.ttf && \
|
||||
ln -s /usr/share/fonts/ttf-dejavu/DejaVuSans.ttf /usr/share/zabbix/assets/fonts/graphfont.ttf && \
|
||||
chown --quiet -R apache:apache /usr/share/zabbix/ && \
|
||||
apk del ${APK_FLAGS_COMMON} --purge \
|
||||
build-dependencies && \
|
||||
rm -rf /var/cache/apk/* && \
|
||||
rm -rf /root/.subversion
|
||||
rm -rf /var/cache/apk/*
|
||||
|
||||
EXPOSE 80/TCP 443/TCP
|
||||
|
||||
|
@ -1,16 +1,16 @@
|
||||
diff -Nru zabbix-2.5.0.orig/frontends/php/include/defines.inc.php zabbix-2.5.0/frontends/php/include/defines.inc.php
|
||||
--- zabbix-2.5.0.orig/frontends/php/include/defines.inc.php 2015-08-19 17:27:39.000000000 +0900
|
||||
+++ zabbix-2.5.0/frontends/php/include/defines.inc.php 2015-08-22 15:20:12.000000000 +0900
|
||||
@@ -51,7 +51,7 @@
|
||||
@@ -66,7 +66,7 @@
|
||||
define('ZBX_WIDGET_ROWS', 20);
|
||||
|
||||
define('ZBX_FONTPATH', realpath('fonts')); // where to search for font (GD > 2.0.18)
|
||||
define('ZBX_FONTPATH', realpath('assets/fonts')); // where to search for font (GD > 2.0.18)
|
||||
-define('ZBX_GRAPH_FONT_NAME', 'DejaVuSans'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
define('ZBX_GRAPH_LEGEND_HEIGHT', 120); // when graph height is less then this value, some legend will not show up
|
||||
|
||||
define('ZBX_SCRIPT_TIMEOUT', 60); // in seconds
|
||||
@@ -96,7 +96,7 @@
|
||||
@@ -111,7 +111,7 @@
|
||||
define('ZBX_ACK_STS_WITH_UNACK', 2);
|
||||
define('ZBX_ACK_STS_WITH_LAST_UNACK', 3);
|
||||
|
||||
|
@ -3,9 +3,9 @@ FROM centos:centos7 as builder
|
||||
ARG YUM_FLAGS_COMMON="-y"
|
||||
ARG YUM_FLAGS_DEV="${YUM_FLAGS_COMMON}"
|
||||
|
||||
ARG MAJOR_VERSION=4.0
|
||||
ARG MAJOR_VERSION=4.4
|
||||
ARG ZBX_VERSION=${MAJOR_VERSION}
|
||||
ARG ZBX_SOURCES=svn://svn.zabbix.com/trunk/
|
||||
ARG ZBX_SOURCES=https://git.zabbix.com/scm/zbx/zabbix.git
|
||||
ENV TERM=xterm ZBX_VERSION=${ZBX_VERSION} ZBX_SOURCES=${ZBX_SOURCES}
|
||||
|
||||
COPY ["conf/tmp/font-config", "/tmp/font-config"]
|
||||
@ -14,15 +14,18 @@ RUN yum --quiet makecache && \
|
||||
yum ${YUM_FLAGS_DEV} install \
|
||||
gettext \
|
||||
patch \
|
||||
subversion && \
|
||||
git && \
|
||||
cd /tmp/ && \
|
||||
svn --quiet export ${ZBX_SOURCES}/frontends/php/ zabbix && \
|
||||
git clone ${ZBX_SOURCES} --branch master --depth 1 --single-branch zabbix-${ZBX_VERSION} && \
|
||||
mkdir /tmp/zabbix/ && \
|
||||
cp -R /tmp/zabbix-${ZBX_VERSION}/frontends/php/* /tmp/zabbix/ && \
|
||||
rm -rf /tmp/zabbix-${ZBX_VERSION}/ && \
|
||||
cd /tmp/zabbix/ && \
|
||||
patch -p3 < /tmp/font-config && \
|
||||
rm /tmp/font-config && \
|
||||
rm -f conf/zabbix.conf.php && \
|
||||
rm -rf tests && \
|
||||
rm /tmp/zabbix/fonts/DejaVuSans.ttf && \
|
||||
rm /tmp/zabbix/assets/fonts/DejaVuSans.ttf && \
|
||||
./locale/make_mo.sh
|
||||
|
||||
FROM centos:centos7
|
||||
@ -34,9 +37,9 @@ ARG VCS_REF
|
||||
ARG YUM_FLAGS_COMMON="-y"
|
||||
ARG YUM_FLAGS_PERSISTENT="${YUM_FLAGS_COMMON}"
|
||||
|
||||
ARG MAJOR_VERSION=4.0
|
||||
ARG MAJOR_VERSION=4.4
|
||||
ARG ZBX_VERSION=${MAJOR_VERSION}
|
||||
ARG ZBX_SOURCES=svn://svn.zabbix.com/trunk/
|
||||
ARG ZBX_SOURCES=https://git.zabbix.com/scm/zbx/zabbix.git
|
||||
ENV TERM=xterm ZBX_VERSION=${ZBX_VERSION} ZBX_SOURCES=${ZBX_SOURCES} \
|
||||
ZBX_TYPE=frontend ZBX_DB_TYPE=postgresql ZBX_OPT_TYPE=apache
|
||||
|
||||
@ -80,10 +83,11 @@ RUN groupadd --system zabbix && \
|
||||
php-pgsql \
|
||||
php-xml \
|
||||
postgresql && \
|
||||
ln -s /usr/share/fonts/dejavu/DejaVuSans.ttf /usr/share/zabbix/fonts/graphfont.ttf && \
|
||||
ln -s /usr/share/fonts/dejavu/DejaVuSans.ttf /usr/share/zabbix/assets/fonts/graphfont.ttf && \
|
||||
cat /usr/share/zabbix/include/locales.inc.php | grep display | grep true | awk '{$1=$1};1' | \
|
||||
cut -d"'" -f 2 | sort | \
|
||||
xargs -I '{}' bash -c 'echo "{}" && localedef -c -i {} -f UTF-8 {}.UTF-8 2>/dev/null' && \
|
||||
chown --quiet -R apache:apache /usr/share/zabbix && \
|
||||
yum ${YUM_FLAGS_PERSISTENT} clean all && \
|
||||
rm -rf /var/cache/yum/
|
||||
|
||||
|
@ -1,18 +1,18 @@
|
||||
diff -Nru zabbix-2.5.0.orig/frontends/php/include/defines.inc.php zabbix-2.5.0/frontends/php/include/defines.inc.php
|
||||
--- zabbix-2.5.0.orig/frontends/php/include/defines.inc.php 2015-08-19 17:27:39.000000000 +0900
|
||||
+++ zabbix-2.5.0/frontends/php/include/defines.inc.php 2015-08-22 15:20:12.000000000 +0900
|
||||
@@ -42,7 +42,7 @@
|
||||
@@ -66,7 +66,7 @@
|
||||
define('ZBX_WIDGET_ROWS', 20);
|
||||
|
||||
define('ZBX_FONTPATH', realpath('fonts')); // where to search for font (GD > 2.0.18)
|
||||
define('ZBX_FONTPATH', realpath('assets/fonts')); // where to search for font (GD > 2.0.18)
|
||||
-define('ZBX_GRAPH_FONT_NAME', 'DejaVuSans'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
define('ZBX_GRAPH_LEGEND_HEIGHT', 120); // when graph height is less then this value, some legend will not show up
|
||||
|
||||
define('ZBX_SCRIPT_TIMEOUT', 60); // in seconds
|
||||
@@ -90,7 +90,7 @@
|
||||
define('EVENTS_OPTION_ALL', 2);
|
||||
define('EVENTS_OPTION_NOT_ACK', 3);
|
||||
@@ -111,7 +111,7 @@
|
||||
define('ZBX_ACK_STS_WITH_UNACK', 2);
|
||||
define('ZBX_ACK_STS_WITH_LAST_UNACK', 3);
|
||||
|
||||
-define('ZBX_FONT_NAME', 'DejaVuSans');
|
||||
+define('ZBX_FONT_NAME', 'graphfont');
|
||||
|
@ -53,9 +53,9 @@ RUN apt-get ${APT_FLAGS_COMMON} update && \
|
||||
apt-get ${APT_FLAGS_COMMON} clean && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ARG MAJOR_VERSION=4.0
|
||||
ARG MAJOR_VERSION=4.4
|
||||
ARG ZBX_VERSION=${MAJOR_VERSION}
|
||||
ARG ZBX_SOURCES=svn://svn.zabbix.com/trunk/
|
||||
ARG ZBX_SOURCES=https://git.zabbix.com/scm/zbx/zabbix.git
|
||||
ENV ZBX_VERSION=${ZBX_VERSION} ZBX_SOURCES=${ZBX_SOURCES}
|
||||
|
||||
LABEL org.label-schema.usage="https://www.zabbix.com/documentation/${MAJOR_VERSION}/manual/installation/containers" \
|
||||
@ -69,17 +69,21 @@ RUN apt-get ${APT_FLAGS_COMMON} update && \
|
||||
apt-get ${APT_FLAGS_DEV} install \
|
||||
gettext \
|
||||
patch \
|
||||
subversion && \
|
||||
ca-certificates \
|
||||
git && \
|
||||
cd /usr/share/ && \
|
||||
svn --quiet export ${ZBX_SOURCES}/frontends/php/ zabbix && \
|
||||
git clone ${ZBX_SOURCES} --branch master --depth 1 --single-branch zabbix-${ZBX_VERSION} && \
|
||||
mkdir /usr/share/zabbix/ && \
|
||||
cp -R /usr/share/zabbix-${ZBX_VERSION}/frontends/php/* /usr/share/zabbix/ && \
|
||||
rm -rf /usr/share/zabbix-${ZBX_VERSION}/ && \
|
||||
cd /usr/share/zabbix/ && \
|
||||
patch -p3 < /tmp/font-config && \
|
||||
rm /tmp/font-config && \
|
||||
rm -f conf/zabbix.conf.php && \
|
||||
rm -rf tests && \
|
||||
rm /usr/share/zabbix/fonts/DejaVuSans.ttf && \
|
||||
rm /usr/share/zabbix/assets/fonts/DejaVuSans.ttf && \
|
||||
./locale/make_mo.sh && \
|
||||
update-alternatives --install /usr/share/zabbix/fonts/graphfont.ttf \
|
||||
update-alternatives --install /usr/share/zabbix/assets/fonts/graphfont.ttf \
|
||||
zabbix-frontend-font /usr/share/fonts/truetype/ttf-dejavu/DejaVuSans.ttf 10 && \
|
||||
mkdir -p /var/lib/locales/supported.d/ && \
|
||||
rm -f /var/lib/locales/supported.d/local && \
|
||||
@ -89,14 +93,15 @@ RUN apt-get ${APT_FLAGS_COMMON} update && \
|
||||
dpkg-reconfigure locales && \
|
||||
find /usr/share/zabbix/locale -name '*.po' | xargs rm -f && \
|
||||
find /usr/share/zabbix/locale -name '*.sh' | xargs rm -f && \
|
||||
chown --quiet -R www-data:www-data /usr/share/zabbix && \
|
||||
apt-get ${APT_FLAGS_COMMON} purge \
|
||||
gettext \
|
||||
patch \
|
||||
subversion && \
|
||||
ca-certificates \
|
||||
git && \
|
||||
apt-get ${APT_FLAGS_COMMON} autoremove && \
|
||||
apt-get ${APT_FLAGS_COMMON} clean && \
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
rm -rf /root/.subversion
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
EXPOSE 80/TCP 443/TCP
|
||||
|
||||
|
@ -1,18 +1,18 @@
|
||||
diff -Nru zabbix-2.5.0.orig/frontends/php/include/defines.inc.php zabbix-2.5.0/frontends/php/include/defines.inc.php
|
||||
--- zabbix-2.5.0.orig/frontends/php/include/defines.inc.php 2015-08-19 17:27:39.000000000 +0900
|
||||
+++ zabbix-2.5.0/frontends/php/include/defines.inc.php 2015-08-22 15:20:12.000000000 +0900
|
||||
@@ -42,7 +42,7 @@
|
||||
@@ -66,7 +66,7 @@
|
||||
define('ZBX_WIDGET_ROWS', 20);
|
||||
|
||||
define('ZBX_FONTPATH', realpath('fonts')); // where to search for font (GD > 2.0.18)
|
||||
define('ZBX_FONTPATH', realpath('assets/fonts')); // where to search for font (GD > 2.0.18)
|
||||
-define('ZBX_GRAPH_FONT_NAME', 'DejaVuSans'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
+define('ZBX_GRAPH_FONT_NAME', 'graphfont'); // font file name
|
||||
define('ZBX_GRAPH_LEGEND_HEIGHT', 120); // when graph height is less then this value, some legend will not show up
|
||||
|
||||
define('ZBX_SCRIPT_TIMEOUT', 60); // in seconds
|
||||
@@ -90,7 +90,7 @@
|
||||
define('EVENTS_OPTION_ALL', 2);
|
||||
define('EVENTS_OPTION_NOT_ACK', 3);
|
||||
@@ -111,7 +111,7 @@
|
||||
define('ZBX_ACK_STS_WITH_UNACK', 2);
|
||||
define('ZBX_ACK_STS_WITH_LAST_UNACK', 3);
|
||||
|
||||
-define('ZBX_FONT_NAME', 'DejaVuSans');
|
||||
+define('ZBX_FONT_NAME', 'graphfont');
|
||||
|
Reference in New Issue
Block a user