/[smecontribs]/rpms/zabbix/contribs9/zabbix.spec
ViewVC logotype

Contents of /rpms/zabbix/contribs9/zabbix.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.3 - (show annotations) (download)
Thu May 14 03:45:18 2020 UTC (4 years, 5 months ago) by jpp
Branch: MAIN
Changes since 1.2: +10 -0 lines
* Sun May 10 2020 Jean-Philipe Pialasse <tests@pialasse.com> 4.4.6-2.sme
- import 4.4.6 for SME SErver [SME: 10944]
- add Provides: zabbix to prevent conflicts on upgrade from fws when
  both agent and server or proxy are installed

1 Name: zabbix
2 Version: 4.4.6
3 Release: %{?alphatag:0.}1%{?alphatag}%{?dist}
4 Summary: The Enterprise-class open source monitoring solution
5 Group: Applications/Internet
6 License: GPLv2+
7 URL: http://www.zabbix.com/
8 Source0: %{name}-%{version}%{?alphatag}.tar.gz
9 Source1: zabbix-web22.conf
10 Source2: zabbix-web24.conf
11 Source3: zabbix-logrotate.in
12 Source4: zabbix-java-gateway.init
13 Source5: zabbix-agent.init
14 Source6: zabbix-server.init
15 Source7: zabbix-proxy.init
16 Source10: zabbix-agent.service
17 Source11: zabbix-server.service
18 Source12: zabbix-proxy.service
19 Source13: zabbix-java-gateway.service
20 Source14: zabbix_java_gateway-sysd
21 Source15: zabbix-tmpfiles.conf
22 Source16: zabbix-php-fpm.conf
23 Source17: zabbix-web-fcgi.conf
24 Source18: zabbix-nginx.conf
25 Source19: zabbix-agent2.service
26 Source20: zabbix-agent.sysconfig
27 Patch0: config.patch
28 Patch1: fping3-sourceip-option.patch
29
30 Buildroot: %{_tmppath}/zabbix-%{version}-%{release}-root-%(%{__id_u} -n)
31
32 %ifarch x86_64
33 %if 0%{?rhel} >= 8
34 %define build_agent2 1
35 %endif
36 %endif
37
38 # FIXME: Building debuginfo is broken on RHEL-8. Disabled for now.
39 %if 0%{?rhel} == 8
40 %define debug_package %{nil}
41 %endif
42
43 %if 0%{?rhel} >= 6
44 %define build_server 1
45 %endif
46
47 BuildRequires: mysql-devel
48 BuildRequires: postgresql-devel
49 BuildRequires: net-snmp-devel
50 BuildRequires: openldap-devel
51 BuildRequires: gnutls-devel
52 BuildRequires: sqlite-devel
53 BuildRequires: unixODBC-devel
54 BuildRequires: curl-devel >= 7.13.1
55 BuildRequires: OpenIPMI-devel >= 2
56 %if 0%{?rhel} >= 8
57 BuildRequires: libssh-devel >= 0.9.0
58 %else
59 BuildRequires: libssh2-devel >= 1.0.0
60 %endif
61 BuildRequires: java-devel >= 1.6.0
62 BuildRequires: libxml2-devel
63 BuildRequires: pcre-devel
64 BuildRequires: libevent-devel
65 %if 0%{?rhel} >= 6
66 BuildRequires: openssl-devel >= 1.0.1
67 %endif
68 %if 0%{?rhel} >= 7
69 BuildRequires: systemd
70 %endif
71
72 %description
73 Zabbix is the ultimate enterprise-level software designed for
74 real-time monitoring of millions of metrics collected from tens of
75 thousands of servers, virtual machines and network devices.
76
77 %package agent
78 Summary: Old Zabbix Agent
79 Group: Applications/Internet
80 Requires: logrotate
81 Requires(pre): /usr/sbin/useradd
82 %if 0%{?rhel} >= 7
83 Requires(post): systemd
84 Requires(preun): systemd
85 Requires(preun): systemd
86 %else
87 Requires(post): /sbin/chkconfig
88 Requires(preun): /sbin/chkconfig
89 Requires(preun): /sbin/service
90 Requires(postun): /sbin/service
91 %endif
92 Obsoletes: zabbix
93
94 %if 0%{?build_agent2} != 1
95 %description agent
96 Zabbix agent to be installed on monitored systems.
97
98 %else
99 %description agent
100 Old implementation of zabbix agent.
101 To be installed on monitored systems.
102
103 %package agent2
104 Summary: New Zabbix Agent
105 Group: Applications/Internet
106 Requires: logrotate
107 Requires(post): systemd
108 Requires(preun): systemd
109 Requires(preun): systemd
110 Obsoletes: zabbix
111
112 %description agent2
113 New implementation of zabbix agent.
114 To be installed on monitored systems.
115 %endif
116
117 %package get
118 Summary: Zabbix Get
119 Group: Applications/Internet
120
121 %description get
122 Zabbix get command line utility.
123
124 %package sender
125 Summary: Zabbix Sender
126 Group: Applications/Internet
127
128 %description sender
129 Zabbix sender command line utility.
130
131 %package js
132 Summary: Zabbix JS
133 Group: Applications/Internet
134
135 %description js
136 Zabbix js command line utility.
137
138 %package proxy-mysql
139 Summary: Zabbix proxy for MySQL or MariaDB database
140 Group: Applications/Internet
141 Requires: fping
142 %if 0%{?rhel} >= 7
143 Requires(post): systemd
144 Requires(preun): systemd
145 Requires(postun): systemd
146 %else
147 Requires(post): /sbin/chkconfig
148 Requires(preun): /sbin/chkconfig
149 Requires(preun): /sbin/service
150 Requires(postun): /sbin/service
151 %endif
152 Provides: zabbix-proxy = %{version}-%{release}
153 Provides: zabbix-proxy-implementation = %{version}-%{release}
154 Obsoletes: zabbix
155 Obsoletes: zabbix-proxy
156 Provides: zabbix
157
158 %description proxy-mysql
159 Zabbix proxy with MySQL or MariaDB database support.
160
161 %package proxy-pgsql
162 Summary: Zabbix proxy for PostgreSQL database
163 Group: Applications/Internet
164 Requires: fping
165 %if 0%{?rhel} >= 7
166 Requires(post): systemd
167 Requires(preun): systemd
168 Requires(postun): systemd
169 %else
170 Requires(post): /sbin/chkconfig
171 Requires(preun): /sbin/chkconfig
172 Requires(preun): /sbin/service
173 Requires(postun): /sbin/service
174 %endif
175 Provides: zabbix-proxy = %{version}-%{release}
176 Provides: zabbix-proxy-implementation = %{version}-%{release}
177 Obsoletes: zabbix
178 Obsoletes: zabbix-proxy
179 Provides: zabbix
180
181 %description proxy-pgsql
182 Zabbix proxy with PostgreSQL database support.
183
184 %package proxy-sqlite3
185 Summary: Zabbix proxy for SQLite3 database
186 Group: Applications/Internet
187 Requires: fping
188 %if 0%{?rhel} >= 7
189 Requires(post): systemd
190 Requires(preun): systemd
191 Requires(postun): systemd
192 %else
193 Requires(post): /sbin/chkconfig
194 Requires(preun): /sbin/chkconfig
195 Requires(preun): /sbin/service
196 Requires(postun): /sbin/service
197 %endif
198 Provides: zabbix-proxy = %{version}-%{release}
199 Provides: zabbix-proxy-implementation = %{version}-%{release}
200 Obsoletes: zabbix
201 Obsoletes: zabbix-proxy
202 Provides: zabbix
203
204 %description proxy-sqlite3
205 Zabbix proxy with SQLite3 database support.
206
207 %package java-gateway
208 Summary: Zabbix java gateway
209 Group: Applications/Internet
210 %if 0%{?rhel} >= 7
211 Requires: java-headless >= 1.6.0
212 %else
213 Requires: java >= 1.6.0
214 %endif
215 %if 0%{?rhel} >= 7
216 Requires(post): systemd
217 Requires(preun): systemd
218 Requires(postun): systemd
219 %else
220 Requires(post): /sbin/chkconfig
221 Requires(preun): /sbin/chkconfig
222 Requires(preun): /sbin/service
223 Requires(postun): /sbin/service
224 %endif
225 Obsoletes: zabbix
226
227 %description java-gateway
228 Zabbix java gateway
229
230 %if 0%{?build_server}
231 %package server-mysql
232 Summary: Zabbix server for MySQL or MariaDB database
233 Group: Applications/Internet
234 Requires: fping
235 %if 0%{?rhel} >= 7
236 Requires(post): systemd
237 Requires(preun): systemd
238 Requires(postun): systemd
239 %else
240 Requires(post): /sbin/chkconfig
241 Requires(preun): /sbin/chkconfig
242 Requires(preun): /sbin/service
243 Requires(postun): /sbin/service
244 %endif
245 Provides: zabbix-server = %{version}-%{release}
246 Provides: zabbix-server-implementation = %{version}-%{release}
247 Obsoletes: zabbix
248 Obsoletes: zabbix-server
249
250 %description server-mysql
251 Zabbix server with MySQL or MariaDB database support.
252
253 %package server-pgsql
254 Summary: Zabbix server for PostgresSQL database
255 Group: Applications/Internet
256 Requires: fping
257 %if 0%{?rhel} >= 7
258 Requires(post): systemd
259 Requires(preun): systemd
260 Requires(postun): systemd
261 %else
262 Requires(post): /sbin/chkconfig
263 Requires(preun): /sbin/chkconfig
264 Requires(preun): /sbin/service
265 Requires(postun): /sbin/service
266 %endif
267 Provides: zabbix-server = %{version}-%{release}
268 Provides: zabbix-server-implementation = %{version}-%{release}
269 Obsoletes: zabbix
270 Obsoletes: zabbix-server
271 Provides: zabbix
272
273 %description server-pgsql
274 Zabbix server with PostgresSQL database support.
275
276 %package web
277 Summary: Zabbix web frontend common package
278 Group: Application/Internet
279 BuildArch: noarch
280 %if 0%{?rhel} == 7
281 Requires: httpd
282 Requires: php >= 5.4
283 %endif
284 %if 0%{?rhel} >= 7
285 Requires: php-gd
286 Requires: php-bcmath
287 Requires: php-mbstring
288 Requires: php-xml
289 Requires: php-ldap
290 %endif
291 %if 0%{?rhel} >= 8
292 Requires: php-fpm
293 Requires: php-json
294 %endif
295 Requires: dejavu-sans-fonts
296 Requires: zabbix-web-database = %{version}-%{release}
297 Requires(post): %{_sbindir}/update-alternatives
298 Requires(preun): %{_sbindir}/update-alternatives
299
300 %description web
301 Zabbix web frontend common package
302
303 %package web-mysql
304 Summary: Zabbix web frontend for MySQL
305 Group: Applications/Internet
306 BuildArch: noarch
307 %if 0%{?rhel} == 7
308 Requires: php-mysql
309 %endif
310 %if 0%{?rhel} == 8
311 Requires: php-mysqlnd
312 %endif
313 Requires: zabbix-web = %{version}-%{release}
314 Provides: zabbix-web-database = %{version}-%{release}
315 %if 0%{?rhel} >= 8
316 Suggests: zabbix-apache-conf
317 Suggests: zabbix-nginx-conf
318 %endif
319
320 %description web-mysql
321 Zabbix web frontend for MySQL
322
323 %package web-pgsql
324 Summary: Zabbix web frontend for PostgreSQL
325 Group: Applications/Internet
326 BuildArch: noarch
327 %if 0%{?rhel} >= 7
328 Requires: php-pgsql
329 %endif
330 Requires: zabbix-web = %{version}-%{release}
331 Provides: zabbix-web-database = %{version}-%{release}
332
333 %description web-pgsql
334 Zabbix web frontend for PostgreSQL
335
336 %package web-japanese
337 Summary: Japanese font settings for Zabbix frontend
338 Group: Applications/Internet
339 BuildArch: noarch
340 %if 0%{?rhel} >= 8
341 Requires: google-noto-sans-cjk-ttc-fonts
342 Requires: glibc-langpack-ja
343 %else
344 Requires: vlgothic-p-fonts
345 %endif
346 Requires: zabbix-web = %{version}-%{release}
347 Requires(post): %{_sbindir}/update-alternatives
348 Requires(preun): %{_sbindir}/update-alternatives
349
350 %description web-japanese
351 Japanese font configuration for Zabbix web frontend
352
353 %if 0%{?rhel} >= 8
354 %package apache-conf
355 Summary: Automatic zabbix frontend configuration with apache
356 Group: Applications/Internet
357 BuildArch: noarch
358 Requires: zabbix-web
359 Requires: httpd
360 Requires: php >= 5.4
361
362 %description apache-conf
363 Automatic zabbix frontend configuration with apache
364 %endif
365
366 %if 0%{?rhel} >= 7
367 %package nginx-conf
368 Summary: Automatic zabbix frontend configuration with nginx and php-fpm
369 Group: Applications/Internet
370 BuildArch: noarch
371 Requires: zabbix-web
372 Requires: nginx
373 Requires: php-fpm
374
375 %description nginx-conf
376 Automatic zabbix frontend configuration with nginx and php-fpm
377 %endif
378
379 %endif
380
381 %prep
382 %setup0 -q -n %{name}-%{version}%{?alphatag}
383 %patch0 -p1
384 %if 0%{?rhel} >= 7
385 %patch1 -p1
386 %endif
387
388 ## remove font file
389 rm -f frontends/php/assets/fonts/DejaVuSans.ttf
390
391 # replace font in defines.inc.php
392 sed -i -r "s/(define\(.*_FONT_NAME.*)DejaVuSans/\1graphfont/" \
393 frontends/php/include/defines.inc.php
394
395 # remove .htaccess files
396 rm -f frontends/php/app/.htaccess
397 rm -f frontends/php/conf/.htaccess
398 rm -f frontends/php/include/.htaccess
399 rm -f frontends/php/local/.htaccess
400
401 # remove translation source files and scripts
402 find frontends/php/locale -name '*.po' | xargs rm -f
403 find frontends/php/locale -name '*.sh' | xargs rm -f
404
405 # traceroute command path for global script
406 sed -i -e 's|/usr/bin/traceroute|/bin/traceroute|' database/mysql/data.sql
407 sed -i -e 's|/usr/bin/traceroute|/bin/traceroute|' database/postgresql/data.sql
408 sed -i -e 's|/usr/bin/traceroute|/bin/traceroute|' database/sqlite3/data.sql
409
410 # change log directory for Java Gateway
411 sed -i -e 's|/tmp/zabbix_java.log|/var/log/zabbix/zabbix_java_gateway.log|g' src/zabbix_java/lib/logback.xml
412
413 %if 0%{?build_server}
414 # copy sql files for servers
415 cat database/mysql/schema.sql > database/mysql/create.sql
416 cat database/mysql/images.sql >> database/mysql/create.sql
417 cat database/mysql/data.sql >> database/mysql/create.sql
418 gzip database/mysql/create.sql
419
420 cat database/postgresql/schema.sql > database/postgresql/create.sql
421 cat database/postgresql/images.sql >> database/postgresql/create.sql
422 cat database/postgresql/data.sql >> database/postgresql/create.sql
423 gzip database/postgresql/create.sql
424 gzip database/postgresql/timescaledb.sql
425 %endif
426
427 # sql files for proxyes
428 gzip database/mysql/schema.sql
429 gzip database/postgresql/schema.sql
430 gzip database/sqlite3/schema.sql
431
432 %build
433
434 build_flags="
435 --enable-dependency-tracking
436 --sysconfdir=/etc/zabbix
437 --libdir=%{_libdir}/zabbix
438 --enable-agent
439 %if 0%{?build_agent2}
440 --enable-agent2
441 %endif
442 --enable-proxy
443 --enable-ipv6
444 --enable-java
445 --with-net-snmp
446 --with-ldap
447 --with-libcurl
448 --with-openipmi
449 --with-unixodbc
450 %if 0%{?rhel} >= 8
451 --with-ssh
452 %else
453 --with-ssh2
454 %endif
455 --with-libxml2
456 --with-libevent
457 --with-libpcre
458 "
459
460 %if 0%{?rhel} >= 6
461 build_flags="$build_flags --with-openssl"
462 %endif
463
464 %configure $build_flags --with-sqlite3
465 make %{?_smp_mflags}
466 mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_sqlite3
467
468 %if 0%{?build_server}
469 build_flags="$build_flags --enable-server"
470 %endif
471
472 %configure $build_flags --with-mysql
473 make %{?_smp_mflags}
474 %if 0%{?build_server}
475 mv src/zabbix_server/zabbix_server src/zabbix_server/zabbix_server_mysql
476 %endif
477 mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_mysql
478
479 %configure $build_flags --with-postgresql
480 make %{?_smp_mflags}
481 %if 0%{?build_server}
482 mv src/zabbix_server/zabbix_server src/zabbix_server/zabbix_server_pgsql
483 %endif
484 mv src/zabbix_proxy/zabbix_proxy src/zabbix_proxy/zabbix_proxy_pgsql
485
486 %if 0%{?build_server}
487 touch src/zabbix_server/zabbix_server
488 %endif
489 touch src/zabbix_proxy/zabbix_proxy
490
491 %install
492
493 rm -rf $RPM_BUILD_ROOT
494
495 # install
496 %if 0%{?build_agent2}
497 make DESTDIR=$RPM_BUILD_ROOT GOBIN=$RPM_BUILD_ROOT%{_sbindir} install
498 %else
499 make DESTDIR=$RPM_BUILD_ROOT install
500 %endif
501
502 # install necessary directories
503 mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/zabbix
504 mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/run/zabbix
505
506 # install server and proxy binaries
507 %if 0%{?build_server}
508 install -m 0755 -p src/zabbix_server/zabbix_server_* $RPM_BUILD_ROOT%{_sbindir}/
509 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_server
510 %endif
511 install -m 0755 -p src/zabbix_proxy/zabbix_proxy_* $RPM_BUILD_ROOT%{_sbindir}/
512 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_proxy
513
514 # delete unnecessary files from java gateway
515 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_java/settings.sh
516 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_java/startup.sh
517 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_java/shutdown.sh
518
519 # install scripts and modules directories
520 mkdir -p $RPM_BUILD_ROOT/usr/lib/zabbix
521 %if 0%{?build_server}
522 mv $RPM_BUILD_ROOT%{_datadir}/zabbix/alertscripts $RPM_BUILD_ROOT/usr/lib/zabbix
523 %endif
524 mv $RPM_BUILD_ROOT%{_datadir}/zabbix/externalscripts $RPM_BUILD_ROOT/usr/lib/zabbix
525
526 %if 0%{?rhel} >= 7
527 mv $RPM_BUILD_ROOT%{_sbindir}/zabbix_java/lib/logback.xml $RPM_BUILD_ROOT/%{_sysconfdir}/zabbix/zabbix_java_gateway_logback.xml
528 rm $RPM_BUILD_ROOT%{_sbindir}/zabbix_java/lib/logback-console.xml
529 mv $RPM_BUILD_ROOT%{_sbindir}/zabbix_java $RPM_BUILD_ROOT/%{_datadir}/zabbix-java-gateway
530 install -m 0755 -p %{SOURCE14} $RPM_BUILD_ROOT%{_sbindir}/zabbix_java_gateway
531 %endif
532
533 %if 0%{?build_server}
534 # install frontend files
535 find frontends/php -name '*.orig' | xargs rm -f
536 cp -a frontends/php/* $RPM_BUILD_ROOT%{_datadir}/zabbix
537
538 # install frontend configuration files
539 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/web
540 touch $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/web/zabbix.conf.php
541 mv $RPM_BUILD_ROOT%{_datadir}/zabbix/conf/maintenance.inc.php $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/web/
542
543 # drop config files in place
544 %if 0%{?rhel} >= 7
545 install -Dm 0644 -p %{SOURCE16} $RPM_BUILD_ROOT%{_sysconfdir}/php-fpm.d/zabbix.conf
546 install -Dm 0644 -p %{SOURCE18} $RPM_BUILD_ROOT%{_sysconfdir}/nginx/conf.d/zabbix.conf
547 %else
548 install -Dm 0644 -p %{SOURCE2} conf/httpd24-example.conf
549 install -Dm 0644 -p %{SOURCE1} conf/httpd22-example.conf
550 %endif
551
552 %if 0%{?rhel} == 7
553 install -Dm 0644 -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/zabbix.conf
554 %endif
555
556 %if 0%{?rhel} == 8
557 install -Dm 0644 -p %{SOURCE17} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/zabbix.conf
558 install -Dm 0644 -p %{SOURCE2} conf/httpd24-example.conf
559 %endif
560
561 %endif
562 #build_server
563
564 # install configuration files
565 mv $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_agentd.conf.d $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_agentd.d
566 %if 0%{?build_agent2}
567 mkdir $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_agent2.d
568 %endif
569 mv $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_proxy.conf.d $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_proxy.d
570 %if 0%{?build_server}
571 mv $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_server.conf.d $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_server.d
572 %endif
573
574 install -dm 755 $RPM_BUILD_ROOT%{_docdir}/zabbix-agent-%{version}
575
576 cat conf/zabbix_agentd.conf | sed \
577 -e '/^# PidFile=/a \\nPidFile=%{_localstatedir}/run/zabbix/zabbix_agentd.pid' \
578 -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_agentd.log|g' \
579 -e '/^# LogFileSize=.*/a \\nLogFileSize=0' \
580 -e '/^# Include=$/a \\nInclude=%{_sysconfdir}/zabbix/zabbix_agentd.d/*.conf' \
581 > $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_agentd.conf
582
583
584 %if 0%{?build_agent2}
585 cat src/go/conf/zabbix_agent2.conf | sed \
586 -e '/^# PidFile=/a \\nPidFile=%{_localstatedir}/run/zabbix/zabbix_agent2.pid' \
587 -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_agent2.log|g' \
588 -e '/^# LogFileSize=.*/a \\nLogFileSize=0' \
589 -e '/^# Include=$/a \\nInclude=%{_sysconfdir}/zabbix/zabbix_agent2.d/*.conf' \
590 > $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_agent2.conf
591
592 cp man/zabbix_agent2.man $RPM_BUILD_ROOT%{_mandir}/man8/zabbix_agent2.8
593 %endif
594
595 %if 0%{?build_server}
596 cat conf/zabbix_server.conf | sed \
597 -e '/^# PidFile=/a \\nPidFile=%{_localstatedir}/run/zabbix/zabbix_server.pid' \
598 -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_server.log|g' \
599 -e '/^# LogFileSize=/a \\nLogFileSize=0' \
600 -e '/^# AlertScriptsPath=/a \\nAlertScriptsPath=/usr/lib/zabbix/alertscripts' \
601 -e '/^# ExternalScripts=/a \\nExternalScripts=/usr/lib/zabbix/externalscripts' \
602 -e 's|^DBUser=root|DBUser=zabbix|g' \
603 -e '/^# SNMPTrapperFile=.*/a \\nSNMPTrapperFile=/var/log/snmptrap/snmptrap.log' \
604 -e '/^# SocketDir=.*/a \\nSocketDir=/var/run/zabbix' \
605 > $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_server.conf
606 %endif
607
608 cat conf/zabbix_proxy.conf | sed \
609 -e '/^# PidFile=/a \\nPidFile=%{_localstatedir}/run/zabbix/zabbix_proxy.pid' \
610 -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_proxy.log|g' \
611 -e '/^# LogFileSize=/a \\nLogFileSize=0' \
612 -e '/^# ExternalScripts=/a \\nExternalScripts=/usr/lib/zabbix/externalscripts' \
613 -e 's|^DBUser=root|DBUser=zabbix|g' \
614 -e '/^# SNMPTrapperFile=.*/a \\nSNMPTrapperFile=/var/log/snmptrap/snmptrap.log' \
615 -e '/^# SocketDir=.*/a \\nSocketDir=/var/run/zabbix' \
616 > $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_proxy.conf
617
618 cat src/zabbix_java/settings.sh | sed \
619 -e 's|^PID_FILE=.*|PID_FILE="/var/run/zabbix/zabbix_java.pid"|g' \
620 > $RPM_BUILD_ROOT%{_sysconfdir}/zabbix/zabbix_java_gateway.conf
621
622 # install logrotate configuration files
623 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
624 %if 0%{?build_server}
625 cat %{SOURCE3} | sed \
626 -e 's|COMPONENT|server|g' \
627 > $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-server
628 %endif
629 cat %{SOURCE3} | sed \
630 -e 's|COMPONENT|agentd|g' \
631 > $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-agent
632 %if 0%{?build_agent2}
633 cat %{SOURCE3} | sed \
634 -e 's|COMPONENT|agent2|g' \
635 > $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-agent2
636 %endif
637 cat %{SOURCE3} | sed \
638 -e 's|COMPONENT|proxy|g' \
639 > $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/zabbix-proxy
640
641 # install startup scripts
642 %if 0%{?rhel} >= 7
643 install -Dm 0644 -p %{SOURCE10} $RPM_BUILD_ROOT%{_unitdir}/zabbix-agent.service
644 %if 0%{?build_server}
645 install -Dm 0644 -p %{SOURCE11} $RPM_BUILD_ROOT%{_unitdir}/zabbix-server.service
646 %endif
647 install -Dm 0644 -p %{SOURCE12} $RPM_BUILD_ROOT%{_unitdir}/zabbix-proxy.service
648 install -Dm 0644 -p %{SOURCE13} $RPM_BUILD_ROOT%{_unitdir}/zabbix-java-gateway.service
649 %else
650 install -Dm 0755 -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-java-gateway
651 install -Dm 0755 -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-agent
652 %if 0%{?build_server}
653 install -Dm 0755 -p %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-server
654 %endif
655 install -Dm 0755 -p %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/zabbix-proxy
656 %endif
657
658 %if 0%{?build_agent2}
659 install -Dm 0644 -p %{SOURCE19} $RPM_BUILD_ROOT%{_unitdir}/zabbix-agent2.service
660 %endif
661
662 %if 0%{?rhel} <= 6
663 install -Dm 0644 -p %{SOURCE20} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/zabbix-agent
664 %endif
665
666 # install systemd-tmpfiles conf
667 %if 0%{?rhel} >= 7
668 install -Dm 0644 -p %{SOURCE15} $RPM_BUILD_ROOT%{_prefix}/lib/tmpfiles.d/zabbix-agent.conf
669 %if 0%{?build_server}
670 install -Dm 0644 -p %{SOURCE15} $RPM_BUILD_ROOT%{_prefix}/lib/tmpfiles.d/zabbix-server.conf
671 %endif
672 install -Dm 0644 -p %{SOURCE15} $RPM_BUILD_ROOT%{_prefix}/lib/tmpfiles.d/zabbix-proxy.conf
673 install -Dm 0644 -p %{SOURCE15} $RPM_BUILD_ROOT%{_prefix}/lib/tmpfiles.d/zabbix-java-gateway.conf
674 %endif
675
676 %if 0%{?build_agent2}
677 install -Dm 0644 -p %{SOURCE15} $RPM_BUILD_ROOT%{_prefix}/lib/tmpfiles.d/zabbix_agent2.conf
678 %endif
679
680 %clean
681 rm -rf $RPM_BUILD_ROOT
682
683 %pre agent
684 getent group zabbix > /dev/null || groupadd -r zabbix
685 getent passwd zabbix > /dev/null || \
686 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
687 -c "Zabbix Monitoring System" zabbix
688 :
689
690 %post agent
691 %if 0%{?rhel} >= 7
692 %systemd_post zabbix-agent.service
693 %else
694 /sbin/chkconfig --add zabbix-agent || :
695 %endif
696
697 %posttrans agent
698 # preserve old userparameter_mysql.conf file during upgrade
699 if [ -f %{_sysconfdir}/zabbix/zabbix_agentd.d/userparameter_mysql.conf.rpmsave ] && [ ! -f %{_sysconfdir}/zabbix/zabbix_agentd.d/userparameter_mysql.conf ]; then
700 cp -vn %{_sysconfdir}/zabbix/zabbix_agentd.d/userparameter_mysql.conf.rpmsave %{_sysconfdir}/zabbix/zabbix_agentd.d/userparameter_mysql.conf
701 fi
702 :
703
704 %if 0%{?build_agent2}
705 %pre agent2
706 getent group zabbix > /dev/null || groupadd -r zabbix
707 getent passwd zabbix > /dev/null || \
708 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
709 -c "Zabbix Monitoring System" zabbix
710 :
711
712 %post agent2
713 %systemd_post zabbix-agent2.service
714 :
715 %endif
716
717 %pre proxy-mysql
718 getent group zabbix > /dev/null || groupadd -r zabbix
719 getent passwd zabbix > /dev/null || \
720 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
721 -c "Zabbix Monitoring System" zabbix
722 :
723
724 %pre proxy-pgsql
725 getent group zabbix > /dev/null || groupadd -r zabbix
726 getent passwd zabbix > /dev/null || \
727 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
728 -c "Zabbix Monitoring System" zabbix
729 :
730
731 %pre proxy-sqlite3
732 getent group zabbix > /dev/null || groupadd -r zabbix
733 getent passwd zabbix > /dev/null || \
734 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
735 -c "Zabbix Monitoring System" zabbix
736 :
737
738 %pre java-gateway
739 getent group zabbix > /dev/null || groupadd -r zabbix
740 getent passwd zabbix > /dev/null || \
741 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
742 -c "Zabbix Monitoring System" zabbix
743 :
744
745 %if 0%{?build_server}
746 %pre server-mysql
747 getent group zabbix > /dev/null || groupadd -r zabbix
748 getent passwd zabbix > /dev/null || \
749 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
750 -c "Zabbix Monitoring System" zabbix
751 :
752
753 %pre server-pgsql
754 getent group zabbix > /dev/null || groupadd -r zabbix
755 getent passwd zabbix > /dev/null || \
756 useradd -r -g zabbix -d %{_localstatedir}/lib/zabbix -s /sbin/nologin \
757 -c "Zabbix Monitoring System" zabbix
758 :
759 %endif
760
761 %post proxy-mysql
762 %if 0%{?rhel} >= 7
763 %systemd_post zabbix-proxy.service
764 %else
765 /sbin/chkconfig --add zabbix-proxy
766 %endif
767 /usr/sbin/update-alternatives --install %{_sbindir}/zabbix_proxy \
768 zabbix-proxy %{_sbindir}/zabbix_proxy_mysql 10
769 :
770
771 %post proxy-pgsql
772 %if 0%{?rhel} >= 7
773 %systemd_post zabbix-proxy.service
774 %else
775 /sbin/chkconfig --add zabbix-proxy
776 %endif
777 /usr/sbin/update-alternatives --install %{_sbindir}/zabbix_proxy \
778 zabbix-proxy %{_sbindir}/zabbix_proxy_pgsql 10
779 :
780
781 %post proxy-sqlite3
782 %if 0%{?rhel} >= 7
783 %systemd_post zabbix-proxy.service
784 %else
785 /sbin/chkconfig --add zabbix-proxy
786 %endif
787 /usr/sbin/update-alternatives --install %{_sbindir}/zabbix_proxy \
788 zabbix-proxy %{_sbindir}/zabbix_proxy_sqlite3 10
789 :
790
791 %post java-gateway
792 %if 0%{?rhel} >= 7
793 %systemd_post zabbix-java-gateway.service
794 %else
795 /sbin/chkconfig --add zabbix-java-gateway
796 %endif
797 :
798
799 %if 0%{?build_server}
800 %post server-mysql
801 %if 0%{?rhel} >= 7
802 %systemd_post zabbix-server.service
803 %else
804 /sbin/chkconfig --add zabbix-server
805 %endif
806 /usr/sbin/update-alternatives --install %{_sbindir}/zabbix_server \
807 zabbix-server %{_sbindir}/zabbix_server_mysql 10
808 :
809
810 %post server-pgsql
811 %if 0%{?rhel} >= 7
812 %systemd_post zabbix-server.service
813 %else
814 /sbin/chkconfig --add zabbix-server
815 %endif
816 /usr/sbin/update-alternatives --install %{_sbindir}/zabbix_server \
817 zabbix-server %{_sbindir}/zabbix_server_pgsql 10
818 :
819
820 %post web
821 # The fonts directory was moved into assets subdirectory at one point.
822 #
823 # This broke invocation of update-alternatives command below, because the target link for zabbix-web-font changed
824 # from zabbix/fonts/graphfont.ttf to zabbix/assets/fonts/graphfont.ttf
825 #
826 # We handle this movement by deleting /var/lib/alternatives/zabbix-web-font file if it contains the old target link.
827 # We also remove symlink at zabbix/fonts/graphfont.ttf to have the old fonts directory be deleted during update.
828 if [ -f /var/lib/alternatives/zabbix-web-font ] && \
829 [ -z "$(grep %{_datadir}/zabbix/assets/fonts/graphfont.ttf /var/lib/alternatives/zabbix-web-font)" ]
830 then
831 rm /var/lib/alternatives/zabbix-web-font
832 if [ -h %{_datadir}/zabbix/fonts/graphfont.ttf ]; then
833 rm %{_datadir}/zabbix/fonts/graphfont.ttf
834 fi
835 fi
836 /usr/sbin/update-alternatives --install %{_datadir}/zabbix/assets/fonts/graphfont.ttf \
837 zabbix-web-font %{_datadir}/fonts/dejavu/DejaVuSans.ttf 10
838 :
839
840 %post web-japanese
841 /usr/sbin/update-alternatives --install %{_datadir}/zabbix/assets/fonts/graphfont.ttf zabbix-web-font \
842 %if 0%{?rhel} >= 8
843 %{_datadir}/fonts/google-noto-cjk/NotoSansCJK-Regular.ttc 20
844 %else
845 %{_datadir}/fonts/vlgothic/VL-PGothic-Regular.ttf 20
846 %endif
847 :
848
849 %if 0%{?rhel} >= 8
850 # The user apache must be available for these to work.
851 # It is provided by httpd or php-fpm packages.
852 %post apache-conf
853 if [ -d /etc/zabbix/web ]; then
854 chown apache:apache /etc/zabbix/web/
855 fi
856 :
857 %endif
858
859 %if 0%{?rhel} >= 7
860 %post nginx-conf
861 if [ -d /etc/zabbix/web ]; then
862 chown apache:apache /etc/zabbix/web/
863 fi
864 :
865 %endif
866
867 %endif
868
869 %preun agent
870 if [ "$1" = 0 ]; then
871 %if 0%{?rhel} >= 7
872 %systemd_preun zabbix-agent.service
873 %else
874 /sbin/service zabbix-agent stop >/dev/null 2>&1
875 /sbin/chkconfig --del zabbix-agent
876 %endif
877 fi
878 :
879
880 %if 0%{?build_agent2}
881 %preun agent2
882 %systemd_preun zabbix-agent2.service
883 :
884 %endif
885
886 %preun proxy-mysql
887 if [ "$1" = 0 ]; then
888 %if 0%{?rhel} >= 7
889 %systemd_preun zabbix-proxy.service
890 %else
891 /sbin/service zabbix-proxy stop >/dev/null 2>&1
892 /sbin/chkconfig --del zabbix-proxy
893 %endif
894 /usr/sbin/update-alternatives --remove zabbix-proxy \
895 %{_sbindir}/zabbix_proxy_mysql
896 fi
897 :
898
899 %preun proxy-pgsql
900 if [ "$1" = 0 ]; then
901 %if 0%{?rhel} >= 7
902 %systemd_preun zabbix-proxy.service
903 %else
904 /sbin/service zabbix-proxy stop >/dev/null 2>&1
905 /sbin/chkconfig --del zabbix-proxy
906 %endif
907 /usr/sbin/update-alternatives --remove zabbix-proxy \
908 %{_sbindir}/zabbix_proxy_pgsql
909 fi
910 :
911
912 %preun proxy-sqlite3
913 if [ "$1" = 0 ]; then
914 %if 0%{?rhel} >= 7
915 %systemd_preun zabbix-proxy.service
916 %else
917 /sbin/service zabbix-proxy stop >/dev/null 2>&1
918 /sbin/chkconfig --del zabbix-proxy
919 %endif
920 /usr/sbin/update-alternatives --remove zabbix-proxy \
921 %{_sbindir}/zabbix_proxy_sqlite3
922 fi
923 :
924
925 %preun java-gateway
926 if [ $1 -eq 0 ]; then
927 %if 0%{?rhel} >= 7
928 %systemd_preun zabbix-java-gateway.service
929 %else
930 /sbin/service zabbix-java-gateway stop >/dev/null 2>&1
931 /sbin/chkconfig --del zabbix-java-gateway
932 %endif
933 fi
934 :
935
936 %if 0%{?build_server}
937 %preun server-mysql
938 if [ "$1" = 0 ]; then
939 %if 0%{?rhel} >= 7
940 %systemd_preun zabbix-server.service
941 %else
942 /sbin/service zabbix-server stop >/dev/null 2>&1
943 /sbin/chkconfig --del zabbix-server
944 %endif
945 /usr/sbin/update-alternatives --remove zabbix-server \
946 %{_sbindir}/zabbix_server_mysql
947 fi
948 :
949
950 %preun server-pgsql
951 if [ "$1" = 0 ]; then
952 %if 0%{?rhel} >= 7
953 %systemd_preun zabbix-server.service
954 %else
955 /sbin/service zabbix-server stop >/dev/null 2>&1
956 /sbin/chkconfig --del zabbix-server
957 %endif
958 /usr/sbin/update-alternatives --remove zabbix-server \
959 %{_sbindir}/zabbix_server_pgsql
960 fi
961 :
962
963 %preun web
964 if [ "$1" = 0 ]; then
965 /usr/sbin/update-alternatives --remove zabbix-web-font \
966 %{_datadir}/fonts/dejavu/DejaVuSans.ttf
967 fi
968 :
969
970 %preun web-japanese
971 if [ "$1" = 0 ]; then
972 /usr/sbin/update-alternatives --remove zabbix-web-font \
973 %if 0%{?rhel} >= 8
974 %{_datadir}/fonts/google-noto-cjk/NotoSansCJK-Regular.ttc
975 %else
976 %{_datadir}/fonts/vlgothic/VL-PGothic-Regular.ttf
977 %endif
978 fi
979 :
980 %endif
981
982 %postun agent
983 %if 0%{?rhel} >= 7
984 %systemd_postun_with_restart zabbix-agent.service
985 %else
986 if [ $1 -ge 1 ]; then
987 /sbin/service zabbix-agent try-restart >/dev/null 2>&1 || :
988 fi
989 %endif
990
991 %if 0%{?build_agent2}
992 %postun agent2
993 %systemd_postun_with_restart zabbix-agent2.service
994 %endif
995
996 %postun proxy-mysql
997 %if 0%{?rhel} >= 7
998 %systemd_postun_with_restart zabbix-proxy.service
999 %else
1000 if [ $1 -ge 1 ]; then
1001 /sbin/service zabbix-proxy try-restart >/dev/null 2>&1 || :
1002 fi
1003 %endif
1004
1005 %postun proxy-pgsql
1006 %if 0%{?rhel} >= 7
1007 %systemd_postun_with_restart zabbix-proxy.service
1008 %else
1009 if [ $1 -ge 1 ]; then
1010 /sbin/service zabbix-proxy try-restart >/dev/null 2>&1 || :
1011 fi
1012 %endif
1013
1014 %postun proxy-sqlite3
1015 %if 0%{?rhel} >= 7
1016 %systemd_postun_with_restart zabbix-proxy.service
1017 %else
1018 if [ $1 -ge 1 ]; then
1019 /sbin/service zabbix-proxy try-restart >/dev/null 2>&1 || :
1020 fi
1021 %endif
1022
1023 %postun java-gateway
1024 %if 0%{?rhel} >= 7
1025 %systemd_postun_with_restart zabbix-java-gateway.service
1026 %else
1027 if [ $1 -gt 1 ]; then
1028 /sbin/service zabbix-java-gateway condrestart >/dev/null 2>&1 || :
1029 fi
1030 %endif
1031
1032 %if 0%{?build_server}
1033 %postun server-mysql
1034 %if 0%{?rhel} >= 7
1035 %systemd_postun_with_restart zabbix-server.service
1036 %else
1037 if [ $1 -ge 1 ]; then
1038 /sbin/service zabbix-server try-restart >/dev/null 2>&1 || :
1039 fi
1040 %endif
1041
1042 %postun server-pgsql
1043 %if 0%{?rhel} >= 7
1044 %systemd_postun_with_restart zabbix-server.service
1045 %else
1046 if [ $1 -ge 1 ]; then
1047 /sbin/service zabbix-server try-restart >/dev/null 2>&1 || :
1048 fi
1049 %endif
1050 %endif
1051
1052 %files agent
1053 %defattr(-,root,root,-)
1054 %doc AUTHORS ChangeLog COPYING NEWS README conf/zabbix_agentd/userparameter_mysql.conf
1055 %config(noreplace) %{_sysconfdir}/zabbix/zabbix_agentd.conf
1056 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-agent
1057 %dir %{_sysconfdir}/zabbix/zabbix_agentd.d
1058 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1059 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1060 %{_sbindir}/zabbix_agentd
1061 %{_mandir}/man8/zabbix_agentd.8*
1062 %if 0%{?rhel} >= 7
1063 %{_unitdir}/zabbix-agent.service
1064 %{_prefix}/lib/tmpfiles.d/zabbix-agent.conf
1065 %else
1066 %{_sysconfdir}/init.d/zabbix-agent
1067 %config(noreplace) %{_sysconfdir}/sysconfig/zabbix-agent
1068 %endif
1069
1070 %if 0%{?build_agent2}
1071 %files agent2
1072 %defattr(-,root,root,-)
1073 %doc AUTHORS ChangeLog COPYING NEWS README
1074 %config(noreplace) %{_sysconfdir}/zabbix/zabbix_agent2.conf
1075 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-agent2
1076 %dir %{_sysconfdir}/zabbix/zabbix_agent2.d
1077 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1078 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1079 %{_sbindir}/zabbix_agent2
1080 %{_mandir}/man8/zabbix_agent2.8*
1081 %{_unitdir}/zabbix-agent2.service
1082 %{_prefix}/lib/tmpfiles.d/zabbix_agent2.conf
1083 %endif
1084
1085 %files get
1086 %defattr(-,root,root,-)
1087 %doc AUTHORS ChangeLog COPYING NEWS README
1088 %{_bindir}/zabbix_get
1089 %{_mandir}/man1/zabbix_get.1*
1090
1091 %files sender
1092 %defattr(-,root,root,-)
1093 %doc AUTHORS ChangeLog COPYING NEWS README
1094 %{_bindir}/zabbix_sender
1095 %{_mandir}/man1/zabbix_sender.1*
1096
1097 %files js
1098 %defattr(-,root,root,-)
1099 %doc AUTHORS ChangeLog COPYING NEWS README
1100 %{_bindir}/zabbix_js
1101
1102 %files proxy-mysql
1103 %defattr(-,root,root,-)
1104 %doc AUTHORS ChangeLog COPYING NEWS README
1105 %doc database/mysql/schema.sql.gz
1106 %attr(0640,root,zabbix) %config(noreplace) %{_sysconfdir}/zabbix/zabbix_proxy.conf
1107 %dir /usr/lib/zabbix/externalscripts
1108 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-proxy
1109 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1110 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1111 %{_mandir}/man8/zabbix_proxy.8*
1112 %if 0%{?rhel} >= 7
1113 %{_unitdir}/zabbix-proxy.service
1114 %{_prefix}/lib/tmpfiles.d/zabbix-proxy.conf
1115 %else
1116 %{_sysconfdir}/init.d/zabbix-proxy
1117 %endif
1118 %{_sbindir}/zabbix_proxy_mysql
1119
1120 %files proxy-pgsql
1121 %defattr(-,root,root,-)
1122 %doc AUTHORS ChangeLog COPYING NEWS README
1123 %doc database/postgresql/schema.sql.gz
1124 %attr(0640,root,zabbix) %config(noreplace) %{_sysconfdir}/zabbix/zabbix_proxy.conf
1125 %dir /usr/lib/zabbix/externalscripts
1126 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-proxy
1127 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1128 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1129 %{_mandir}/man8/zabbix_proxy.8*
1130 %if 0%{?rhel} >= 7
1131 %{_unitdir}/zabbix-proxy.service
1132 %{_prefix}/lib/tmpfiles.d/zabbix-proxy.conf
1133 %else
1134 %{_sysconfdir}/init.d/zabbix-proxy
1135 %endif
1136 %{_sbindir}/zabbix_proxy_pgsql
1137
1138 %files proxy-sqlite3
1139 %defattr(-,root,root,-)
1140 %doc AUTHORS ChangeLog COPYING NEWS README
1141 %doc database/sqlite3/schema.sql.gz
1142 %attr(0640,root,zabbix) %config(noreplace) %{_sysconfdir}/zabbix/zabbix_proxy.conf
1143 %dir /usr/lib/zabbix/externalscripts
1144 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-proxy
1145 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1146 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1147 %{_mandir}/man8/zabbix_proxy.8*
1148 %if 0%{?rhel} >= 7
1149 %{_unitdir}/zabbix-proxy.service
1150 %{_prefix}/lib/tmpfiles.d/zabbix-proxy.conf
1151 %else
1152 %{_sysconfdir}/init.d/zabbix-proxy
1153 %endif
1154 %{_sbindir}/zabbix_proxy_sqlite3
1155
1156 %files java-gateway
1157 %defattr(-,root,root,-)
1158 %doc AUTHORS ChangeLog COPYING NEWS README
1159 %config(noreplace) %{_sysconfdir}/zabbix/zabbix_java_gateway.conf
1160 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1161 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1162 %if 0%{?rhel} >= 7
1163 %{_datadir}/zabbix-java-gateway
1164 %{_sbindir}/zabbix_java_gateway
1165 %{_unitdir}/zabbix-java-gateway.service
1166 %{_prefix}/lib/tmpfiles.d/zabbix-java-gateway.conf
1167 %config(noreplace) %{_sysconfdir}/zabbix/zabbix_java_gateway_logback.xml
1168 %else
1169 %{_sbindir}/zabbix_java
1170 %{_sysconfdir}/init.d/zabbix-java-gateway
1171 %endif
1172
1173 %if 0%{?build_server}
1174 %files server-mysql
1175 %defattr(-,root,root,-)
1176 %doc AUTHORS ChangeLog COPYING NEWS README
1177 %doc database/mysql/create.sql.gz
1178 %attr(0640,root,zabbix) %config(noreplace) %{_sysconfdir}/zabbix/zabbix_server.conf
1179 %dir /usr/lib/zabbix/alertscripts
1180 %dir /usr/lib/zabbix/externalscripts
1181 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-server
1182 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1183 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1184 %{_mandir}/man8/zabbix_server.8*
1185 %if 0%{?rhel} >= 7
1186 %{_unitdir}/zabbix-server.service
1187 %{_prefix}/lib/tmpfiles.d/zabbix-server.conf
1188 %else
1189 %{_sysconfdir}/init.d/zabbix-server
1190 %endif
1191 %{_sbindir}/zabbix_server_mysql
1192
1193 %files server-pgsql
1194 %defattr(-,root,root,-)
1195 %doc AUTHORS ChangeLog COPYING NEWS README
1196 %doc database/postgresql/create.sql.gz
1197 %doc database/postgresql/timescaledb.sql.gz
1198 %attr(0640,root,zabbix) %config(noreplace) %{_sysconfdir}/zabbix/zabbix_server.conf
1199 %dir /usr/lib/zabbix/alertscripts
1200 %dir /usr/lib/zabbix/externalscripts
1201 %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix-server
1202 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/zabbix
1203 %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/run/zabbix
1204 %{_mandir}/man8/zabbix_server.8*
1205 %if 0%{?rhel} >= 7
1206 %{_unitdir}/zabbix-server.service
1207 %{_prefix}/lib/tmpfiles.d/zabbix-server.conf
1208 %else
1209 %{_sysconfdir}/init.d/zabbix-server
1210 %endif
1211 %{_sbindir}/zabbix_server_pgsql
1212
1213 %files web
1214 %defattr(-,root,root,-)
1215 %doc AUTHORS ChangeLog COPYING NEWS README
1216 %dir %attr(0750,apache,apache) %{_sysconfdir}/zabbix/web
1217 %if 0%{?rhel} >= 8
1218 %config(noreplace) %{_sysconfdir}/php-fpm.d/zabbix.conf
1219 %endif
1220 %if 0%{?rhel} == 7
1221 %config(noreplace) %{_sysconfdir}/httpd/conf.d/zabbix.conf
1222 %endif
1223 %if 0%{?rhel} <= 6
1224 %doc conf/httpd22-example.conf conf/httpd24-example.conf
1225 %endif
1226 %ghost %attr(0644,apache,apache) %config(noreplace) %{_sysconfdir}/zabbix/web/zabbix.conf.php
1227 %config(noreplace) %{_sysconfdir}/zabbix/web/maintenance.inc.php
1228 %{_datadir}/zabbix
1229
1230 %files web-mysql
1231 %defattr(-,root,root,-)
1232
1233 %files web-pgsql
1234 %defattr(-,root,root,-)
1235
1236 %files web-japanese
1237 %defattr(-,root,root,-)
1238
1239 %if 0%{?rhel} >= 8
1240 %files apache-conf
1241 %doc AUTHORS ChangeLog COPYING NEWS README
1242 %config(noreplace) %{_sysconfdir}/httpd/conf.d/zabbix.conf
1243 %endif
1244
1245 %if 0%{?rhel} >= 7
1246 %files nginx-conf
1247 %doc AUTHORS ChangeLog COPYING NEWS README
1248 %config(noreplace) %{_sysconfdir}/nginx/conf.d/zabbix.conf
1249 %config(noreplace) %{_sysconfdir}/php-fpm.d/zabbix.conf
1250 %endif
1251
1252 %endif
1253
1254 %changelog
1255 * Sun May 10 2020 Jean-Philipe Pialasse <tests@pialasse.com> 4.4.6-2.sme
1256 - import 4.4.6 for SME SErver [SME: 10944]
1257 - add Provides: zabbix to prevent conflicts on upgrade from fws when
1258 both agent and server or proxy are installed
1259
1260 * Fri Feb 21 2020 Zabbix Packager <info@zabbix.com> - 4.4.6-1
1261 - update to 4.4.6
1262 - using libssh instead of libssh2 on rhel/centos 8
1263 - fixed font configuration in pre/post scriptlets on rhel-8
1264
1265 * Wed Jan 29 2020 Zabbix Packager <info@zabbix.com> - 4.4.5-2
1266 - added posttrans script that preserves /etc/zabbix/zabbix_agentd.d/userparameter_mysql.conf file
1267 - added config(noreplace) to /etc/sysconfig/zabbix-agent
1268
1269 * Fri Jan 17 2020 Zabbix Packager <info@zabbix.com> - 4.4.5-1
1270 - update to 4.4.5
1271 - added zabbix-js package
1272 - moved /etc/zabbix/zabbix_agentd.d/userparameter_mysql.conf file to /usr/share/doc/zabbix-agent-<vers>/ (ZBX-14399)
1273 - using zabbix-agent2.service instead of zabbix-agent.service in agent2 preun
1274 - setting user for zabbix agent in /etc/sysconfig/zabbix-agent file on rhel <= 6
1275
1276 * Tue Jan 07 2020 Zabbix Packager <info@zabbix.com> - 4.4.4-2
1277 - build of rhel-5 packages to be resigned with gpg version 3
1278
1279 * Thu Dec 19 2019 Zabbix Packager <info@zabbix.com> - 4.4.4-1
1280 - update to 4.4.4
1281 added After=<database>.service directives to server and proxy service files
1282
1283 * Wed Nov 27 2019 Zabbix Packager <info@zabbix.com> - 4.4.3-1
1284 - update to 4.4.3
1285 added User=zabbix and Group=zabbix directives to agent service file
1286
1287 * Mon Nov 25 2019 Zabbix Packager <info@zabbix.com> - 4.4.2-1
1288 - update to 4.4.2
1289
1290 * Mon Oct 28 2019 Zabbix Packager <info@zabbix.com> - 4.4.1-1
1291 - update to 4.4.1
1292
1293 * Mon Oct 07 2019 Zabbix Packager <info@zabbix.com> 4.4.0-1
1294 - update to 4.4.0
1295
1296 * Thu Oct 03 2019 Zabbix Packager <info@zabbix.com> - 4.4.0-0.5rc1
1297 - update to 4.4.0rc1
1298
1299 * Tue Sep 24 2019 Zabbix Packager <info@zabbix.com> - 4.4.0-0.4beta1
1300 - update to 4.4.0beta1
1301 - added zabbix-agent2 package
1302
1303 * Wed Sep 18 2019 Zabbix Packager <info@zabbix.com> - 4.4.0-0.3alpha3
1304 - update to 4.4.0alpha3
1305
1306 * Thu Aug 15 2019 Zabbix Packager <info@zabbix.com> - 4.4.0-0.2alpha2
1307 - update to 4.4.0alpha2
1308 - using google-noto-sans-cjk-ttc-fonts for graphfont in web-japanese package on rhel-8
1309 - added php-fpm as dependency of zabbix-web packages on rhel-8
1310
1311 * Wed Jul 17 2019 Zabbix Packager <info@zabbix.com> - 4.4.0-0.1alpha1
1312 - update to 4.4.0alpha1
1313 - removed apache config from zabbix-web package
1314 - added dedicated zabbix-apache-conf and zabbix-nginx-conf packages
1315
1316 * Fri Mar 29 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-1
1317 - update to 4.2.0
1318 - removed jabber notifications support and dependency on iksemel library
1319
1320 * Tue Mar 26 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.6rc2
1321 - update to 4.2.0rc2
1322
1323 * Mon Mar 18 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.5rc1
1324 - update to 4.2.0rc1
1325
1326 * Mon Mar 04 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.4beta2
1327 - update to 4.2.0beta2
1328
1329 * Mon Feb 18 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.1beta1
1330 - update to 4.2.0beta1
1331
1332 * Tue Feb 05 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.3alpha3
1333 - build of 4.2.0alpha3 with *.mo files
1334
1335 * Wed Jan 30 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.2alpha3
1336 - added timescaledb.sql.gz to zabbix-server-pgsql package
1337
1338 * Mon Jan 28 2019 Zabbix Packager <info@zabbix.com> - 4.2.0-0.1alpha3
1339 - update to 4.2.0alpha3
1340
1341 * Fri Dec 21 2018 Zabbix Packager <info@zabbix.com> - 4.2.0-0.2alpha2
1342 - update to 4.2.0alpha2
1343
1344 * Tue Nov 27 2018 Zabbix Packager <info@zabbix.com> - 4.2.0-0.1alpha1
1345 - update to 4.2.0alpha1
1346
1347 * Mon Oct 29 2018 Zabbix Packager <info@zabbix.com> - 4.0.1-1
1348 - update to 4.0.1
1349
1350 * Mon Oct 01 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-2
1351 - update to 4.0.0
1352
1353 * Fri Sep 28 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1rc3
1354 - update to 4.0.0rc3
1355
1356 * Tue Sep 25 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1rc2
1357 - update to 4.0.0rc2
1358
1359 * Wed Sep 19 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1rc1
1360 - update to 4.0.0rc1
1361
1362 * Mon Sep 10 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1beta2
1363 - update to 4.0.0beta2
1364
1365 * Tue Aug 28 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1beta1
1366 - update to 4.0.0beta1
1367
1368 * Mon Jul 23 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1alpha9
1369 - update to 4.0.0alpha9
1370 - add PHP variable max_input_vars = 10000, overriding default 1000
1371
1372 * Mon Jun 18 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1alpha8
1373 - update to 4.0.0alpha8
1374
1375 * Wed May 30 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1alpha7
1376 - update to 4.0.0alpha7
1377
1378 * Fri Apr 27 2018 Zabbix Packager <info@zabbix.com> - 4.0.0-1.1alpha6
1379 - update to 4.0.0alpha6
1380 - add support for Ubuntu 18.04 (Bionic)
1381 - move enabling JMX interface on Zabbix java gateway to zabbix_java_gateway.conf
1382
1383 * Mon Mar 26 2018 Vladimir Levijev <vladimir.levijev@zabbix.com> - 4.0.0-1.1alpha5
1384 - update to 4.0.0alpha5
1385
1386 * Tue Feb 27 2018 Vladimir Levijev <vladimir.levijev@zabbix.com> - 4.0.0-1.1alpha4
1387 - update to 4.0.0alpha4
1388
1389 * Mon Feb 05 2018 Vladimir Levijev <vladimir.levijev@zabbix.com> - 4.0.0-1.1alpha3
1390 - update to 4.0.0alpha3
1391
1392 * Tue Jan 09 2018 Vladimir Levijev <vladimir.levijev@zabbix.com> - 4.0.0-1.1alpha2
1393 - update to 4.0.0alpha2
1394
1395 * Tue Dec 19 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 4.0.0-1alpha1
1396 - update to 4.0.0alpha1
1397
1398 * Thu Nov 09 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.4-2
1399 - add missing translation (.mo) files
1400
1401 * Tue Nov 07 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.4-1
1402 - update to 3.4.4
1403 - fix issue with new line character in pid file that resulted in failure when shutting down daemons on RHEL 5
1404
1405 * Tue Oct 17 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.3-1
1406 - update to 3.4.3
1407
1408 * Mon Sep 25 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.2-1
1409 - update to 3.4.2
1410
1411 * Mon Aug 28 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.1-1
1412 - update to 3.4.1
1413 - change SocketDir to /var/run/zabbix
1414
1415 * Mon Aug 21 2017 Vladimir Levijev <vladimir.levijev@zabbix.com> - 3.4.0-1
1416 - update to 3.4.0
1417
1418 * Wed Apr 26 2017 Kodai Terashima <kodai.terashima@zabbix.com> - 3.4.0-1alpha1
1419 - update to 3.4.0alpla1 r68116
1420 - add libpcre and libevent for compile option
1421
1422 * Sun Apr 23 2017 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.5-1
1423 - update to 3.2.5
1424 - add TimeoutSec=0 to systemd service file
1425
1426 * Thu Mar 02 2017 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.4-2
1427 - remove TimeoutSec for systemd
1428
1429 * Mon Feb 27 2017 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.4-1
1430 - update to 3.2.4
1431 - add TimeoutSec for systemd service file
1432
1433 * Wed Dec 21 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.3-1
1434 - update to 3.2.3
1435
1436 * Thu Dec 08 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.2-1
1437 - update to 3.2.2
1438
1439 * Sun Oct 02 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.1-1
1440 - update to 3.2.1
1441 - use zabbix user and group for Java Gateway
1442 - add SuccessExitStatus=143 for Java Gateway servie file
1443
1444 * Tue Sep 13 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0-1
1445 - update to 3.2.0
1446 - add *.conf for Include parameter in agent configuration file
1447
1448 * Mon Sep 12 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0rc2-1
1449 - update to 3.2.0rc2
1450
1451 * Fri Sep 09 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0rc1-1
1452 - update to 3.2.0rc1
1453
1454 * Thu Sep 01 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0beta2-1
1455 - update to 3.2.0beta2
1456
1457 * Fri Aug 26 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0beta1-1
1458 - update to 3.2.0beta1
1459
1460 * Fri Aug 12 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.2.0alpha1-1
1461 - update to 3.2.0alpha1
1462
1463 * Sun Jul 24 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.4-1
1464 - update to 3.0.4
1465
1466 * Sun May 22 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.3-1
1467 - update to 3.0.3
1468 - fix java gateway systemd script to use java options
1469
1470 * Wed Apr 20 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.2-1
1471 - update to 3.0.2
1472 - remove ZBX-10459.patch
1473
1474 * Sat Apr 02 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.1-2
1475 - fix proxy packges doesn't have schema.sql.gz
1476 - add server and web packages for RHEL6
1477 - add ZBX-10459.patch
1478
1479 * Sun Feb 28 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.1-1
1480 - update to 3.0.1
1481 - remove DBSocker parameter
1482
1483 * Sat Feb 20 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0-2
1484 - agent, proxy and java-gateway for RHEL 5 and 6
1485
1486 * Mon Feb 15 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0-1
1487 - update to 3.0.0
1488
1489 * Thu Feb 11 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0rc2
1490 - update to 3.0.0rc2
1491 - add TIMEOUT parameter for java gateway conf
1492
1493 * Thu Feb 04 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0rc1
1494 - update to 3.0.0rc1
1495
1496 * Sat Jan 30 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0beta2
1497 - update to 3.0.0beta2
1498
1499 * Thu Jan 21 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0beta1
1500 - update to 3.0.0beta1
1501
1502 * Thu Jan 14 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha6
1503 - update to 3.0.0alpla6
1504 - remove zabbix_agent conf and binary
1505
1506 * Wed Jan 13 2016 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha5
1507 - update to 3.0.0alpha5
1508
1509 * Fri Nov 13 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha4-1
1510 - update to 3.0.0alpha4
1511
1512 * Thu Oct 29 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha3-2
1513 - fix web-pgsql package dependency
1514 - add --with-openssl option
1515
1516 * Mon Oct 19 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha3-1
1517 - update to 3.0.0alpha3
1518
1519 * Tue Sep 29 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha2-3
1520 - add IfModule for mod_php5 in apache configuration file
1521 - fix missing proxy_mysql alternatives symlink
1522 - chagne snmptrap log filename
1523 - remove include dir from server and proxy conf
1524
1525 * Fri Sep 18 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha2-2
1526 - fix create.sql doesn't contain schema.sql & images.sql
1527
1528 * Tue Sep 15 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 3.0.0alpha2-1
1529 - update to 3.0.0alpha2
1530
1531 * Sat Aug 22 2015 Kodai Terashima <kodai.terashima@zabbix.com> - 2.5.0-1
1532 - create spec file from scratch
1533 - update to 2.5.0

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed