-
Notifications
You must be signed in to change notification settings - Fork 264
Open
Labels
Description
Hi!
I try to build an image according to the instruction for branches/3.0 or tags/3.0.8 on an image of centos. I receive such mistake.
In the Dockerfile file I set value of the ENV ZABBIX_VERSION=branches/3.0 variable
or ENV ZABBIX_VERSION=tags/3.0.8. and every time I receive a error
gcc -fPIC -shared -o zabbix_module_docker.so zabbix_module_docker.c -I../../../include -I../../../src/libs/zbxsysinfo
zabbix_module_docker.c: In function 'zbx_docker_dir_detect':
zabbix_module_docker.c:708:17: error: too many arguments to function 'zbx_regexp_sub'
if (SUCCEED != zbx_regexp_sub(path, mounts_regex, "\\1", &stat_dir) || NULL == stat_dir)
^
In file included from zabbix_module_docker.c:26:0:
../../../include/zbxregexp.h:37:7: note: declared here
char *zbx_regexp_sub(const char *string, const char *pattern, const char *output_template);
^
make: *** [zabbix_module_docker] Error 1`
Full text of a mistake below
Docker version
`docker info
Containers: 3
Running: 0
Paused: 0
Stopped: 3
Images: 41
Server Version: 18.01.0-ce
Storage Driver: overlay
Backing Filesystem: extfs
Supports d_type: true
..........
I need to compile with the tag 3.0.8 since doesn't work with the zabbix_module_docker.so file which I have downloaded already compiled for version 3.0 zabbix-agent.
82922:20180122:184855.259 using configuration file:/etc/zabbix/zabbix_agentd.conf
82922:20180122:184855.259 In load_modules ()
82922:20180122:184855.259 loading module "/export/home/zabbix/zabbix/modules//zabbix_module_docker.so"
82922:20180122:184855.259 can't load module "zabbix_module_docker.so": / export/home/zabbix/zabbix/modules//zabbix_module_docker.so: undefined symbol: zbx_alarm_timed_out
82922:20180122:184855.259 End of load_modules (): FAIL
82922:20180122:184855.259 loading modules failed, exiting..
centos]$ docker build --rm=true -t local/zabbix-docker-module-compilation .
Sending build context to Docker daemon 3.072kB
Step 1/6 : FROM centos:centos7
---> 328edcd84f1b
Step 2/6 : MAINTAINER "Jan Garaj" <[email protected]>
---> Using cache
---> e4a4e81b7984
Step 3/6 : ENV ZABBIX_VERSION=branches/3.0
---> Running in 88f9251cd230
Removing intermediate container 88f9251cd230
---> 41b60f6732ed
Step 4/6 : WORKDIR /root
Removing intermediate container 19a11506dbf2
---> 1d65e2cd7104
Step 5/6 : RUN yum -y -q install git subversion automake autoconf gcc make pcre-devel 1>/dev/null && git clone -q https://github.com/monitoringartist/zabbix-docker-monitoring
---> Running in b8497313a5f4
warning: /var/cache/yum/x86_64/7/updates/packages/apr-1.4.8-3.el7_4.1.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Importing GPG key 0xF4A80EB5:
Userid : "CentOS-7 Key (CentOS 7 Official Signing Key) <[email protected]>"
Fingerprint: 6341 ab27 53d7 8a78 a7c2 7bb1 24c6 a8a7 f4a8 0eb5
Package : centos-release-7-3.1611.el7.centos.x86_64 (@CentOS)
From : /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
Removing intermediate container b8497313a5f4
---> 8f733b64add2
Step 6/6 : RUN svn --quiet export svn://svn.zabbix.com/${ZABBIX_VERSION} ~/zabbix/ && cd ~/zabbix/ && ./bootstrap.sh 1>/dev/null && ./configure --enable-agent 1>/dev/null && cp -R ~/zabbix-docker-monitoring/src/modules/zabbix_module_docker/ ~/zabbix/src/modules/ && cd ~/zabbix/src/modules/zabbix_module_docker && make
---> Running in 374c5ab2ae40
configure.ac:41: installing './compile'
configure.ac:32: installing './config.guess'
configure.ac:32: installing './config.sub'
configure.ac:24: installing './install-sh'
configure.ac:24: installing './missing'
src/libs/zbxalgo/Makefile.am: installing './depcomp'
gcc -fPIC -shared -o zabbix_module_docker.so zabbix_module_docker.c -I../../../include -I../../../src/libs/zbxsysinfo
zabbix_module_docker.c: In function 'zbx_docker_dir_detect':
zabbix_module_docker.c:708:17: error: too many arguments to function 'zbx_regexp_sub'
if (SUCCEED != zbx_regexp_sub(path, mounts_regex, "\\1", &stat_dir) || NULL == stat_dir)
^
In file included from zabbix_module_docker.c:26:0:
../../../include/zbxregexp.h:37:7: note: declared here
char *zbx_regexp_sub(const char *string, const char *pattern, const char *output_template);
^
make: *** [zabbix_module_docker] Error 1
The command '/bin/sh -c svn --quiet export svn://svn.zabbix.com/${ZABBIX_VERSION} ~/zabbix/ && cd ~/zabbix/ && ./bootstrap.sh 1>/dev/null && ./configure --enable-agent 1>/dev/null && cp -R ~/zabbix-docker-monitoring/src/modules/zabbix_module_docker/ ~/zabbix/src/modules/ && cd ~/zabbix/src/modules/zabbix_module_docker && make' returned a non-zero code: 2