/[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.2 - (show annotations) (download)
Thu May 14 03:38:52 2020 UTC (4 years ago) by jpp
Branch: MAIN
CVS Tags: zabbix-4_4_6-1_el6
Changes since 1.1: +1356 -468 lines
import

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

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