From c4c09e3a2835f278fa253c7d864aa5d595dbe1ea Mon Sep 17 00:00:00 2001 From: Alexey Pustovalov Date: Sat, 21 Dec 2024 03:02:58 +0900 Subject: [PATCH] Added new plugin NVIDIA GPU --- Dockerfiles/agent2/alpine/docker-entrypoint.sh | 4 ++++ Dockerfiles/agent2/centos/docker-entrypoint.sh | 4 ++++ Dockerfiles/agent2/ol/docker-entrypoint.sh | 4 ++++ Dockerfiles/agent2/rhel/docker-entrypoint.sh | 4 ++++ Dockerfiles/agent2/ubuntu/docker-entrypoint.sh | 4 ++++ Dockerfiles/agent2/windows/docker-entrypoint.ps1 | 3 +++ Dockerfiles/build-mysql/alpine/Dockerfile | 12 ++++++++++-- Dockerfiles/build-mysql/centos/Dockerfile | 12 ++++++++++-- Dockerfiles/build-mysql/ol/Dockerfile | 12 ++++++++++-- Dockerfiles/build-mysql/rhel/Dockerfile | 12 ++++++++++-- Dockerfiles/build-mysql/ubuntu/Dockerfile | 12 ++++++++++-- Dockerfiles/build-mysql/windows/Dockerfile.agent2 | 15 ++++++++++++++- Dockerfiles/build-pgsql/alpine/Dockerfile | 12 ++++++++++-- Dockerfiles/build-pgsql/centos/Dockerfile | 12 ++++++++++-- Dockerfiles/build-pgsql/ol/Dockerfile | 12 ++++++++++-- Dockerfiles/build-pgsql/rhel/Dockerfile | 12 ++++++++++-- Dockerfiles/build-pgsql/ubuntu/Dockerfile | 12 ++++++++++-- Dockerfiles/build-sqlite3/alpine/Dockerfile | 12 ++++++++++-- Dockerfiles/build-sqlite3/centos/Dockerfile | 12 ++++++++++-- Dockerfiles/build-sqlite3/ol/Dockerfile | 12 ++++++++++-- Dockerfiles/build-sqlite3/rhel/Dockerfile | 12 ++++++++++-- Dockerfiles/build-sqlite3/ubuntu/Dockerfile | 12 ++++++++++-- 22 files changed, 187 insertions(+), 31 deletions(-) diff --git a/Dockerfiles/agent2/alpine/docker-entrypoint.sh b/Dockerfiles/agent2/alpine/docker-entrypoint.sh index bb79832a7..60867594c 100755 --- a/Dockerfiles/agent2/alpine/docker-entrypoint.sh +++ b/Dockerfiles/agent2/alpine/docker-entrypoint.sh @@ -220,6 +220,10 @@ prepare_zbx_agent_plugin_config() { update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/postgresql.conf" "Plugins.PostgreSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/postgresql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/mssql.conf" "Plugins.MSSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/mssql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/ember.conf" "Plugins.EmberPlus.System.Path" "/usr/sbin/zabbix-agent2-plugin/ember-plus" + if command -v nvidia-smi 2>&1 >/dev/null + then + update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/nvidia.conf" "Plugins.NVIDIA.System.Path" "/usr/sbin/zabbix-agent2-plugin/nvidia-gpu" + fi } clear_zbx_env() { diff --git a/Dockerfiles/agent2/centos/docker-entrypoint.sh b/Dockerfiles/agent2/centos/docker-entrypoint.sh index bb79832a7..60867594c 100755 --- a/Dockerfiles/agent2/centos/docker-entrypoint.sh +++ b/Dockerfiles/agent2/centos/docker-entrypoint.sh @@ -220,6 +220,10 @@ prepare_zbx_agent_plugin_config() { update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/postgresql.conf" "Plugins.PostgreSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/postgresql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/mssql.conf" "Plugins.MSSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/mssql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/ember.conf" "Plugins.EmberPlus.System.Path" "/usr/sbin/zabbix-agent2-plugin/ember-plus" + if command -v nvidia-smi 2>&1 >/dev/null + then + update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/nvidia.conf" "Plugins.NVIDIA.System.Path" "/usr/sbin/zabbix-agent2-plugin/nvidia-gpu" + fi } clear_zbx_env() { diff --git a/Dockerfiles/agent2/ol/docker-entrypoint.sh b/Dockerfiles/agent2/ol/docker-entrypoint.sh index bb79832a7..60867594c 100755 --- a/Dockerfiles/agent2/ol/docker-entrypoint.sh +++ b/Dockerfiles/agent2/ol/docker-entrypoint.sh @@ -220,6 +220,10 @@ prepare_zbx_agent_plugin_config() { update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/postgresql.conf" "Plugins.PostgreSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/postgresql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/mssql.conf" "Plugins.MSSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/mssql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/ember.conf" "Plugins.EmberPlus.System.Path" "/usr/sbin/zabbix-agent2-plugin/ember-plus" + if command -v nvidia-smi 2>&1 >/dev/null + then + update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/nvidia.conf" "Plugins.NVIDIA.System.Path" "/usr/sbin/zabbix-agent2-plugin/nvidia-gpu" + fi } clear_zbx_env() { diff --git a/Dockerfiles/agent2/rhel/docker-entrypoint.sh b/Dockerfiles/agent2/rhel/docker-entrypoint.sh index bb79832a7..60867594c 100755 --- a/Dockerfiles/agent2/rhel/docker-entrypoint.sh +++ b/Dockerfiles/agent2/rhel/docker-entrypoint.sh @@ -220,6 +220,10 @@ prepare_zbx_agent_plugin_config() { update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/postgresql.conf" "Plugins.PostgreSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/postgresql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/mssql.conf" "Plugins.MSSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/mssql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/ember.conf" "Plugins.EmberPlus.System.Path" "/usr/sbin/zabbix-agent2-plugin/ember-plus" + if command -v nvidia-smi 2>&1 >/dev/null + then + update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/nvidia.conf" "Plugins.NVIDIA.System.Path" "/usr/sbin/zabbix-agent2-plugin/nvidia-gpu" + fi } clear_zbx_env() { diff --git a/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh b/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh index bb79832a7..60867594c 100755 --- a/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh +++ b/Dockerfiles/agent2/ubuntu/docker-entrypoint.sh @@ -220,6 +220,10 @@ prepare_zbx_agent_plugin_config() { update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/postgresql.conf" "Plugins.PostgreSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/postgresql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/mssql.conf" "Plugins.MSSQL.System.Path" "/usr/sbin/zabbix-agent2-plugin/mssql" update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/ember.conf" "Plugins.EmberPlus.System.Path" "/usr/sbin/zabbix-agent2-plugin/ember-plus" + if command -v nvidia-smi 2>&1 >/dev/null + then + update_config_var "/etc/zabbix/zabbix_agent2.d/plugins.d/nvidia.conf" "Plugins.NVIDIA.System.Path" "/usr/sbin/zabbix-agent2-plugin/nvidia-gpu" + fi } clear_zbx_env() { diff --git a/Dockerfiles/agent2/windows/docker-entrypoint.ps1 b/Dockerfiles/agent2/windows/docker-entrypoint.ps1 index 230bf9c4f..91a0fe4b9 100644 --- a/Dockerfiles/agent2/windows/docker-entrypoint.ps1 +++ b/Dockerfiles/agent2/windows/docker-entrypoint.ps1 @@ -245,6 +245,9 @@ function Prepare-Zbx-Agent-Plugins-Config { Update-Config-Var "$ZabbixConfigDir\zabbix_agent2.d\plugins.d\postgresql.conf" "Plugins.PostgreSQL.System.Path" "$ZabbixUserHomeDir\zabbix-agent2-plugin\postgresql.exe" Update-Config-Var "$ZabbixConfigDir\zabbix_agent2.d\plugins.d\mssql.conf" "Plugins.MSSQL.System.Path" "$ZabbixUserHomeDir\zabbix-agent2-plugin\mssql.exe" Update-Config-Var "$ZabbixConfigDir\zabbix_agent2.d\plugins.d\ember.conf" "Plugins.EmberPlus.System.Path" "$ZabbixUserHomeDir\zabbix-agent2-plugin\ember-plus.exe" + if (Get-Command nvidia-smi.exe -errorAction SilentlyContinue) { + Update-Config-Var "$ZabbixConfigDir\zabbix_agent2.d\plugins.d\nvidia.conf" "Plugins.NVIDIA.System.Path" "$ZabbixUserHomeDir\zabbix-agent2-plugin\nvidia-gpu.exe" + } } function PrepareAgent { diff --git a/Dockerfiles/build-mysql/alpine/Dockerfile b/Dockerfiles/build-mysql/alpine/Dockerfile index 7ce134228..84d3c432d 100644 --- a/Dockerfiles/build-mysql/alpine/Dockerfile +++ b/Dockerfiles/build-mysql/alpine/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -161,4 +162,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-mysql/centos/Dockerfile b/Dockerfiles/build-mysql/centos/Dockerfile index e0427d0e2..1ff0ed7d7 100644 --- a/Dockerfiles/build-mysql/centos/Dockerfile +++ b/Dockerfiles/build-mysql/centos/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -161,4 +162,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-mysql/ol/Dockerfile b/Dockerfiles/build-mysql/ol/Dockerfile index 11ac866af..698706361 100644 --- a/Dockerfiles/build-mysql/ol/Dockerfile +++ b/Dockerfiles/build-mysql/ol/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -161,4 +162,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-mysql/rhel/Dockerfile b/Dockerfiles/build-mysql/rhel/Dockerfile index c6614cd05..f5d1e5015 100644 --- a/Dockerfiles/build-mysql/rhel/Dockerfile +++ b/Dockerfiles/build-mysql/rhel/Dockerfile @@ -40,7 +40,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -172,4 +173,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-mysql/ubuntu/Dockerfile b/Dockerfiles/build-mysql/ubuntu/Dockerfile index 5d2837a52..f39e2c8f5 100644 --- a/Dockerfiles/build-mysql/ubuntu/Dockerfile +++ b/Dockerfiles/build-mysql/ubuntu/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -161,4 +162,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-mysql/windows/Dockerfile.agent2 b/Dockerfiles/build-mysql/windows/Dockerfile.agent2 index 2cbf7e613..393437295 100644 --- a/Dockerfiles/build-mysql/windows/Dockerfile.agent2 +++ b/Dockerfiles/build-mysql/windows/Dockerfile.agent2 @@ -16,6 +16,7 @@ ARG MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git ARG POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git ARG MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git ARG EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git +ARG NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git ARG GIT_BRANCH=master ARG ZBX_PLUGINS_VERSION=${GIT_BRANCH:-$ZBX_VERSION} @@ -25,6 +26,7 @@ ENV ZBX_SOURCES=$ZBX_SOURCES MAJOR_VERSION=$MAJOR_VERSION ZBX_VERSION=$ZBX_VERSI POSTGRESQL_PLUGIN_SOURCES=$POSTGRESQL_PLUGIN_SOURCES POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} ` MSSQL_PLUGIN_SOURCES=$MSSQL_PLUGIN_SOURCES MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} ` EMBER_PLUS_PLUGIN_SOURCES=$EMBER_PLUS_PLUGIN_SOURCES EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} ` + NVIDIA_GPU_PLUGIN_SOURCES=$NVIDIA_GPU_PLUGIN_SOURCES NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} ` ZABBIX_VERSION_RC_NUM=$ZABBIX_VERSION_RC_NUM ` ZBX_SOURCES_DIR=C:\\zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=C:\\zabbix-${ZBX_VERSION}-output @@ -110,7 +112,6 @@ RUN Set-Location -Path $env:SystemDrive\.; ` Copy-Item -Path $env:SystemDrive\mssql-plugin-$env:MSSQL_PLUGIN_VERSION\mssql.conf $env:ZBX_OUTPUT_DIR\conf\zabbix_agent2.d\plugins.d; ` mingw32-make -s clean; ` ` - Write-Host ('Building Zabbix Ember+ plugin {0} version ...' -f $env:EMBER_PLUS_PLUGIN_VERSION); ` git -c advice.detachedHead=false clone $env:EMBER_PLUS_PLUGIN_SOURCES --branch $env:EMBER_PLUS_PLUGIN_VERSION --depth 1 --single-branch $env:SystemDrive\ember-plus-plugin-$env:EMBER_PLUS_PLUGIN_VERSION; ` Set-Location -Path $env:SystemDrive\ember-plus-plugin-$env:EMBER_PLUS_PLUGIN_VERSION; ` @@ -122,4 +123,16 @@ RUN Set-Location -Path $env:SystemDrive\.; ` Copy-Item -Path $env:SystemDrive\ember-plus-plugin-$env:EMBER_PLUS_PLUGIN_VERSION\zabbix-agent2-plugin-ember-plus.exe $env:ZBX_OUTPUT_DIR\zabbix-agent2-plugin\ember-plus.exe; ` Copy-Item -Path $env:SystemDrive\ember-plus-plugin-$env:EMBER_PLUS_PLUGIN_VERSION\ember.conf $env:ZBX_OUTPUT_DIR\conf\zabbix_agent2.d\plugins.d; ` mingw32-make -s clean; ` + ` + Write-Host ('Building NVIDIA GPU plugin {0} version ...' -f $env:NVIDIA_GPU_PLUGIN_VERSION); ` + git -c advice.detachedHead=false clone $env:NVIDIA_GPU_PLUGIN_SOURCES --branch $env:NVIDIA_GPU_PLUGIN_VERSION --depth 1 --single-branch $env:SystemDrive\nvidia-gpu-plugin-$env:NVIDIA_GPU_PLUGIN_VERSION; ` + Set-Location -Path $env:SystemDrive\nvidia-gpu-plugin-$env:NVIDIA_GPU_PLUGIN_VERSION; ` + mingw32-make; ` + ` + Write-Host 'Verifying NVIDIA GPU plugin ("zabbix-agent2-plugin-nvidia-gpu.exe -V") ...'; ` + & $env:SystemDrive\nvidia-gpu-plugin-$env:NVIDIA_GPU_PLUGIN_VERSION\zabbix-agent2-plugin-nvidia-gpu.exe -V; ` + ` + Copy-Item -Path $env:SystemDrive\nvidia-gpu-plugin-$env:NVIDIA_GPU_PLUGIN_VERSION\zabbix-agent2-plugin-nvidia-gpu.exe $env:ZBX_OUTPUT_DIR\zabbix-agent2-plugin\nvidia-gpu.exe; ` + Copy-Item -Path $env:SystemDrive\nvidia-gpu-plugin-$env:NVIDIA_GPU_PLUGIN_VERSION\nvidia.conf $env:ZBX_OUTPUT_DIR\conf\zabbix_agent2.d\plugins.d; ` + mingw32-make -s clean; ` Write-Host 'Zabbix binaries are compiled...'; diff --git a/Dockerfiles/build-pgsql/alpine/Dockerfile b/Dockerfiles/build-pgsql/alpine/Dockerfile index c2b893296..87c88afce 100644 --- a/Dockerfiles/build-pgsql/alpine/Dockerfile +++ b/Dockerfiles/build-pgsql/alpine/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -166,4 +167,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-pgsql/centos/Dockerfile b/Dockerfiles/build-pgsql/centos/Dockerfile index db65bfea2..e536dd0b2 100644 --- a/Dockerfiles/build-pgsql/centos/Dockerfile +++ b/Dockerfiles/build-pgsql/centos/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -165,4 +166,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-pgsql/ol/Dockerfile b/Dockerfiles/build-pgsql/ol/Dockerfile index c314d3df7..07f85459b 100644 --- a/Dockerfiles/build-pgsql/ol/Dockerfile +++ b/Dockerfiles/build-pgsql/ol/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -166,4 +167,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-pgsql/rhel/Dockerfile b/Dockerfiles/build-pgsql/rhel/Dockerfile index c6eab0d08..41bad671e 100644 --- a/Dockerfiles/build-pgsql/rhel/Dockerfile +++ b/Dockerfiles/build-pgsql/rhel/Dockerfile @@ -40,7 +40,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -177,4 +178,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-pgsql/ubuntu/Dockerfile b/Dockerfiles/build-pgsql/ubuntu/Dockerfile index 6ee410ec1..03739a0a1 100644 --- a/Dockerfiles/build-pgsql/ubuntu/Dockerfile +++ b/Dockerfiles/build-pgsql/ubuntu/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -165,4 +166,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-sqlite3/alpine/Dockerfile b/Dockerfiles/build-sqlite3/alpine/Dockerfile index ce6c439d9..300846cc9 100644 --- a/Dockerfiles/build-sqlite3/alpine/Dockerfile +++ b/Dockerfiles/build-sqlite3/alpine/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -138,4 +139,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-sqlite3/centos/Dockerfile b/Dockerfiles/build-sqlite3/centos/Dockerfile index ee91c7798..d39b67422 100644 --- a/Dockerfiles/build-sqlite3/centos/Dockerfile +++ b/Dockerfiles/build-sqlite3/centos/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -138,4 +139,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-sqlite3/ol/Dockerfile b/Dockerfiles/build-sqlite3/ol/Dockerfile index 5d9076f99..b66fc362c 100644 --- a/Dockerfiles/build-sqlite3/ol/Dockerfile +++ b/Dockerfiles/build-sqlite3/ol/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -138,4 +139,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-sqlite3/rhel/Dockerfile b/Dockerfiles/build-sqlite3/rhel/Dockerfile index 52356193a..ea0adfcf5 100644 --- a/Dockerfiles/build-sqlite3/rhel/Dockerfile +++ b/Dockerfiles/build-sqlite3/rhel/Dockerfile @@ -40,7 +40,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -149,4 +150,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ diff --git a/Dockerfiles/build-sqlite3/ubuntu/Dockerfile b/Dockerfiles/build-sqlite3/ubuntu/Dockerfile index 441d37d03..e3485abd3 100644 --- a/Dockerfiles/build-sqlite3/ubuntu/Dockerfile +++ b/Dockerfiles/build-sqlite3/ubuntu/Dockerfile @@ -29,7 +29,8 @@ ENV ZBX_SOURCES_DIR=/tmp/zabbix-${ZBX_VERSION} ZBX_OUTPUT_DIR=/tmp/zabbix-${ZBX_ MONGODB_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mongodb.git MONGODB_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ POSTGRESQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/postgresql.git POSTGRESQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ MSSQL_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/mssql.git MSSQL_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ - EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} + EMBER_PLUS_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/ember-plus.git EMBER_PLUS_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} \ + NVIDIA_GPU_PLUGIN_SOURCES=https://git.zabbix.com/scm/ap/nvidia-gpu.git NVIDIA_GPU_PLUGIN_VERSION=${ZBX_PLUGINS_VERSION} RUN --mount=type=cache,target=/root/.cache/go-build/ \ --mount=type=cache,target=/root/go/ \ @@ -139,4 +140,11 @@ RUN --mount=type=cache,target=/root/.cache/go-build/ \ make && \ strip /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus && \ cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/zabbix-agent2-plugin-ember-plus ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/ember-plus && \ - cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ + cp /tmp/ember-plugin-${EMBER_PLUS_PLUGIN_VERSION}/ember.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/ && \ + cd /tmp/ && \ + git -c advice.detachedHead=false clone ${NVIDIA_GPU_PLUGIN_SOURCES} --branch ${NVIDIA_GPU_PLUGIN_VERSION} --depth 1 --single-branch /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + cd /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION} && \ + make && \ + strip /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/zabbix-agent2-plugin-nvidia-gpu ${ZBX_OUTPUT_DIR}/agent2/sbin/zabbix-agent2-plugin/nvidia-gpu && \ + cp /tmp/nvidia-gpu-plugin-${NVIDIA_GPU_PLUGIN_VERSION}/nvidia.conf ${ZBX_OUTPUT_DIR}/agent2/conf/zabbix_agent2.d/plugins.d/