1 | %bcond_with systemd |
---|
2 | |
---|
3 | %define only_agent 0 |
---|
4 | |
---|
5 | %if %{only_agent} |
---|
6 | %bcond_with server |
---|
7 | %bcond_with proxy |
---|
8 | %bcond_with frontend |
---|
9 | %else |
---|
10 | %bcond_without server |
---|
11 | %bcond_without proxy |
---|
12 | %bcond_without frontend |
---|
13 | %endif |
---|
14 | |
---|
15 | %bcond_without agent |
---|
16 | |
---|
17 | %global php_pkgname php74 |
---|
18 | |
---|
19 | Summary: The Enterprise-class Monitoring Solution for Everyone |
---|
20 | Name: zabbix |
---|
21 | Version: 5.0.3 |
---|
22 | Release: 1%{?_dist_release}%{?with_systemd:.systemd} |
---|
23 | Group: system |
---|
24 | Vendor: Project Vine |
---|
25 | Distribution: Vine Linux |
---|
26 | Packager: iwaim |
---|
27 | |
---|
28 | License: GPLv2 |
---|
29 | URL: https://www.zabbix.com/ |
---|
30 | %global shortver %(echo %{version} | sed -e 's/\.[0-9]*$//') |
---|
31 | Source0: https://cdn.zabbix.com/zabbix/sources/stable/%{shortver}/%{name}-%{version}.tar.gz |
---|
32 | Source1: zabbix_server.init |
---|
33 | Source2: zabbix_proxy.init |
---|
34 | Source3: zabbix_agentd.init |
---|
35 | Source4: zabbix_server.logrotate |
---|
36 | Source5: zabbix_proxy.logrotate |
---|
37 | Source6: zabbix_agentd.logrotate |
---|
38 | |
---|
39 | Source9: %{name}-tmpfiles-zabbix.conf |
---|
40 | # systemd units -- Alternatives switches between them (they state their dependencies) |
---|
41 | # https://support.zabbix.com/browse/ZBXNEXT-1593 |
---|
42 | Source10: %{name}-agent.service |
---|
43 | Source11: %{name}-proxy-mysql.service |
---|
44 | Source12: %{name}-proxy-pgsql.service |
---|
45 | Source14: %{name}-server-mysql.service |
---|
46 | Source15: %{name}-server-pgsql.service |
---|
47 | Source17: %{name}-tmpfiles-zabbixsrv.conf |
---|
48 | |
---|
49 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot |
---|
50 | %if %{with server}%{with proxy} |
---|
51 | BuildRequires: libpq-devel |
---|
52 | BuildRequires: libmariadb-devel |
---|
53 | %endif |
---|
54 | BuildRequires: libevent-devel |
---|
55 | BuildRequires: pcre-devel |
---|
56 | BuildRequires: curl-devel |
---|
57 | BuildRequires: net-snmp-devel |
---|
58 | BuildRequires: OpenIPMI-devel |
---|
59 | BuildRequires: unixODBC-devel |
---|
60 | BuildRequires: libssh2-devel |
---|
61 | BuildRequires: openssl-devel |
---|
62 | |
---|
63 | Requires(pre): glibc-common |
---|
64 | Requires(pre): shadow-utils |
---|
65 | %if %{with systemd} |
---|
66 | BuildRequires: systemd |
---|
67 | %endif |
---|
68 | |
---|
69 | %description |
---|
70 | The Enterprise-class Monitoring Solution for Everyone. |
---|
71 | |
---|
72 | |
---|
73 | %if %{with server} |
---|
74 | %package server-common |
---|
75 | Summary: common files for Zabbix Server |
---|
76 | Group: servers |
---|
77 | Requires: %{name} == %{version}-%{release} |
---|
78 | %if %{with systemd} |
---|
79 | %{?systemd_requires} |
---|
80 | %else |
---|
81 | Requires(post,preun): chkconfig |
---|
82 | Requires(preun,postun): initscripts |
---|
83 | %endif |
---|
84 | |
---|
85 | %description server-common |
---|
86 | This package include common files for Zabbix Server. |
---|
87 | |
---|
88 | |
---|
89 | %package server-mysql |
---|
90 | Summary: Zabbix Server for MySQL/MariaDB |
---|
91 | Group: servers |
---|
92 | Provides: %{name}-server |
---|
93 | Requires: %{name}-server-common == %{version}-%{release} |
---|
94 | |
---|
95 | %description server-mysql |
---|
96 | Zabbix Server for MySQL/MariaDB |
---|
97 | |
---|
98 | |
---|
99 | %package server-postgresql |
---|
100 | Summary: Zabbix Server for PostgreSQL |
---|
101 | Group: servers |
---|
102 | Provides: %{name}-server |
---|
103 | Requires: %{name}-server-common == %{version}-%{release} |
---|
104 | |
---|
105 | %description server-postgresql |
---|
106 | Zabbix Server for PostgreSQL |
---|
107 | |
---|
108 | %endif |
---|
109 | |
---|
110 | |
---|
111 | %if %{with agent} |
---|
112 | %package agent |
---|
113 | Summary: Zabbix Agent |
---|
114 | Group: system |
---|
115 | Requires: %{name} == %{version}-%{release} |
---|
116 | %if %{with systemd} |
---|
117 | %{?systemd_requires} |
---|
118 | %else |
---|
119 | Requires(post,preun): chkconfig |
---|
120 | Requires(preun,postun): initscripts |
---|
121 | %endif |
---|
122 | |
---|
123 | %description agent |
---|
124 | Zabbix Agent |
---|
125 | |
---|
126 | %endif |
---|
127 | |
---|
128 | |
---|
129 | %if %{with proxy} |
---|
130 | %package proxy-common |
---|
131 | Summary: common files for Zabbix Proxy |
---|
132 | Group: servers |
---|
133 | Requires: %{name} == %{version}-%{release} |
---|
134 | %if %{with systemd} |
---|
135 | %{?systemd_requires} |
---|
136 | %else |
---|
137 | Requires(post,preun): chkconfig |
---|
138 | Requires(preun,postun): initscripts |
---|
139 | %endif |
---|
140 | |
---|
141 | %description proxy-common |
---|
142 | This package include common files for Zabbix Proxy |
---|
143 | |
---|
144 | |
---|
145 | %package proxy-mysql |
---|
146 | Summary: Zabbix Proxy for MySQL/MariaDB |
---|
147 | Group: servers |
---|
148 | Provides: %{name}-proxy |
---|
149 | Requires: %{name}-proxy-common == %{version}-%{release} |
---|
150 | |
---|
151 | %description proxy-mysql |
---|
152 | Zabbix Proxy for MySQL/MariaDB |
---|
153 | |
---|
154 | |
---|
155 | %package proxy-postgresql |
---|
156 | Summary: Zabbix Proxy for PostgreSQL |
---|
157 | Group: servers |
---|
158 | Provides: %{name}-proxy |
---|
159 | Requires: %{name}-proxy-common == %{version}-%{release} |
---|
160 | |
---|
161 | %description proxy-postgresql |
---|
162 | Zabbix Proxy for PostgreSQL |
---|
163 | |
---|
164 | %endif |
---|
165 | |
---|
166 | |
---|
167 | %if %{with frontend} |
---|
168 | %package frontend-php |
---|
169 | Summary: Zabbix web frontend with PHP |
---|
170 | Group: servers |
---|
171 | Requires: %{php_pkgname} |
---|
172 | Requires: TrueType-vlgothic |
---|
173 | |
---|
174 | %description frontend-php |
---|
175 | Zabbix web frontend with PHP. |
---|
176 | |
---|
177 | |
---|
178 | %package frontend-php-mysql |
---|
179 | Summary: Zabbix web frontend with PHP and MySQL/MariaDB |
---|
180 | Group: servers |
---|
181 | Provides: %{name}-frontend-php == %{version}-%{release} |
---|
182 | Requires: %{php_pkgname}-mysql |
---|
183 | |
---|
184 | %description frontend-php-mysql |
---|
185 | Zabbix web frontend with PHP and MySQL/MariaDB. |
---|
186 | |
---|
187 | |
---|
188 | %package frontend-php-postgresql |
---|
189 | Summary: Zabbix web frontend with PHP and PostgreSQL |
---|
190 | Group: servers |
---|
191 | Provides: %{name}-frontend-php == %{version}-%{release} |
---|
192 | Requires: %{php_pkgname}-pgsql |
---|
193 | |
---|
194 | %description frontend-php-postgresql |
---|
195 | Zabbix web frontend with PHP and PostgreSQL. |
---|
196 | |
---|
197 | %endif |
---|
198 | |
---|
199 | |
---|
200 | %debug_package |
---|
201 | |
---|
202 | |
---|
203 | %prep |
---|
204 | %setup -q -T -a 0 -c -n zabbix-%{version} |
---|
205 | mv zabbix-%{version} zabbix_mysql |
---|
206 | |
---|
207 | %if %{with server}%{with proxy} |
---|
208 | %setup -q -D -T -a 0 -n zabbix-%{version} |
---|
209 | mv zabbix-%{version} zabbix_pgsql |
---|
210 | %endif |
---|
211 | |
---|
212 | for v in mysql pgsql; do |
---|
213 | pushd zabbix_$v |
---|
214 | sed -i -e 's/DejaVuSans/VL-Gothic-Regular/g' ./ui/include/defines.inc.php |
---|
215 | |
---|
216 | sed -i \ |
---|
217 | -e '\|^# PidFile=.*|a PidFile=/run/zabbix/zabbix_agentd.pid' \ |
---|
218 | -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_agentd.log|' \ |
---|
219 | conf/zabbix_agentd.conf |
---|
220 | |
---|
221 | sed -i \ |
---|
222 | -e '\|^# PidFile=.*|a PidFile=/run/zabbix/zabbix_proxy.pid' \ |
---|
223 | -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_proxy.log|' \ |
---|
224 | conf/zabbix_proxy.conf |
---|
225 | |
---|
226 | sed -i \ |
---|
227 | -e '\|^# PidFile=.*|a PidFile=/run/zabbix/zabbix_server.pid' \ |
---|
228 | -e 's|^LogFile=.*|LogFile=%{_localstatedir}/log/zabbix/zabbix_server.log|' \ |
---|
229 | conf/zabbix_server.conf |
---|
230 | popd |
---|
231 | done |
---|
232 | |
---|
233 | |
---|
234 | %build |
---|
235 | Build() |
---|
236 | { |
---|
237 | perl -pi -e 's|/usr/bin/traceroute|/bin/traceroute|' \ |
---|
238 | ./database/{ibm_db2,mysql,oracle,postgresql,sqlite3}/data.sql |
---|
239 | |
---|
240 | %configure \ |
---|
241 | %{?with_server:--enable-server} \ |
---|
242 | %{?with_proxy:--enable-proxy} \ |
---|
243 | %{?with_agent:--enable-agent} \ |
---|
244 | --enable-ipv6 \ |
---|
245 | --sysconfdir=%{_sysconfdir}/zabbix \ |
---|
246 | --with-libcurl \ |
---|
247 | --with-openipmi \ |
---|
248 | --with-net-snmp \ |
---|
249 | --with-unixodbc \ |
---|
250 | --with-ssh2 \ |
---|
251 | --with-openssl \ |
---|
252 | $@ |
---|
253 | |
---|
254 | %__make |
---|
255 | } |
---|
256 | |
---|
257 | %if %{with server}%{with proxy} |
---|
258 | pushd zabbix_mysql |
---|
259 | Build --with-mysql |
---|
260 | popd |
---|
261 | |
---|
262 | pushd zabbix_pgsql |
---|
263 | Build --with-postgresql |
---|
264 | popd |
---|
265 | %else |
---|
266 | pushd zabbix_mysql |
---|
267 | Build |
---|
268 | popd |
---|
269 | %endif |
---|
270 | |
---|
271 | |
---|
272 | %install |
---|
273 | %__rm -rf %{buildroot} |
---|
274 | pushd zabbix_mysql |
---|
275 | make DESTDIR=%{buildroot} install |
---|
276 | |
---|
277 | %if %{with server} |
---|
278 | mv -f %{buildroot}%{_sbindir}/zabbix_server %{buildroot}%{_sbindir}/zabbix_server.mysql |
---|
279 | %endif |
---|
280 | %if %{with proxy} |
---|
281 | mv -f %{buildroot}%{_sbindir}/zabbix_proxy %{buildroot}%{_sbindir}/zabbix_proxy.mysql |
---|
282 | %endif |
---|
283 | |
---|
284 | # make directories |
---|
285 | %__mkdir_p %{buildroot}%{_localstatedir}/{log,run}/%{name} |
---|
286 | |
---|
287 | # DB |
---|
288 | %__mkdir_p %{buildroot}%{_datadir}/zabbix |
---|
289 | %if %{with server}%{with proxy} |
---|
290 | %__cp -a database/postgresql %{buildroot}%{_datadir}/zabbix/ |
---|
291 | %__cp -a database/mysql %{buildroot}%{_datadir}/zabbix/ |
---|
292 | %endif |
---|
293 | |
---|
294 | %if %{with systemd} |
---|
295 | # unit files |
---|
296 | %__mkdir_p %{buildroot}%{_unitdir} |
---|
297 | # Install different systemd units because of the requirements for DBMS daemons |
---|
298 | install -m 0644 -p %{SOURCE10} %{buildroot}%{_unitdir}/zabbix-agent.service |
---|
299 | install -m 0644 -p %{SOURCE11} %{buildroot}%{_unitdir}/zabbix-proxy-mysql.service |
---|
300 | install -m 0644 -p %{SOURCE12} %{buildroot}%{_unitdir}/zabbix-proxy-pgsql.service |
---|
301 | install -m 0644 -p %{SOURCE14} %{buildroot}%{_unitdir}/zabbix-server-mysql.service |
---|
302 | install -m 0644 -p %{SOURCE15} %{buildroot}%{_unitdir}/zabbix-server-pgsql.service |
---|
303 | |
---|
304 | # systemd tmpfiles |
---|
305 | mkdir -p %{buildroot}%{_prefix}/lib/tmpfiles.d |
---|
306 | install -m 0644 -p %{SOURCE9} %{buildroot}%{_prefix}/lib/tmpfiles.d/zabbix.conf |
---|
307 | |
---|
308 | %else |
---|
309 | # init.d |
---|
310 | %__mkdir_p %{buildroot}%{_initddir} |
---|
311 | %if %{with server} |
---|
312 | %__cp %{SOURCE1} %{buildroot}%{_initddir}/zabbix_server |
---|
313 | %endif |
---|
314 | %if %{with proxy} |
---|
315 | %__cp %{SOURCE2} %{buildroot}%{_initddir}/zabbix_proxy |
---|
316 | %endif |
---|
317 | %if %{with agent} |
---|
318 | %__cp %{SOURCE3} %{buildroot}%{_initddir}/zabbix_agentd |
---|
319 | %endif |
---|
320 | %endif |
---|
321 | |
---|
322 | # logrotate |
---|
323 | %__mkdir_p %{buildroot}%{_sysconfdir}/logrotate.d |
---|
324 | %if %{with server} |
---|
325 | %__cp %{SOURCE4} %{buildroot}%{_sysconfdir}/logrotate.d/zabbix_server |
---|
326 | %endif |
---|
327 | %if %{with proxy} |
---|
328 | %__cp %{SOURCE5} %{buildroot}%{_sysconfdir}/logrotate.d/zabbix_proxy |
---|
329 | %endif |
---|
330 | %if %{with agent} |
---|
331 | %__cp %{SOURCE6} %{buildroot}%{_sysconfdir}/logrotate.d/zabbix_agentd |
---|
332 | %endif |
---|
333 | |
---|
334 | %if %{with frontend} |
---|
335 | # frontend-php |
---|
336 | %__mkdir_p %{buildroot}%{_datadir}/zabbix-frontend |
---|
337 | %__cp -a ui %{buildroot}%{_datadir}/zabbix-frontend/php |
---|
338 | %__rm -f %{buildroot}%{_datadir}/zabbix-frontend/php/assets/fonts/DejaVuSans.ttf |
---|
339 | |
---|
340 | ln -s /usr/share/fonts/TrueType-vlgothic/VL-Gothic-Regular.ttf \ |
---|
341 | %{buildroot}%{_datadir}/zabbix-frontend/php/assets/fonts/ |
---|
342 | %endif |
---|
343 | |
---|
344 | %if %{with proxy} |
---|
345 | # proxy |
---|
346 | mkdir -p %{buildroot}%{_datadir}/zabbix-proxy |
---|
347 | ln -sf ../zabbix/mysql %{buildroot}%{_datadir}/zabbix-proxy/ |
---|
348 | ln -sf ../zabbix/postgresql %{buildroot}%{_datadir}/zabbix-proxy/ |
---|
349 | %endif |
---|
350 | |
---|
351 | popd |
---|
352 | |
---|
353 | %if %{with server}%{with proxy} |
---|
354 | pushd zabbix_pgsql |
---|
355 | install -m755 src/zabbix_server/zabbix_server %{buildroot}%{_sbindir}/zabbix_server.pgsql |
---|
356 | install -m755 src/zabbix_proxy/zabbix_proxy %{buildroot}%{_sbindir}/zabbix_proxy.pgsql |
---|
357 | popd |
---|
358 | %endif |
---|
359 | |
---|
360 | |
---|
361 | %clean |
---|
362 | %__rm -rf %{buildroot} |
---|
363 | |
---|
364 | |
---|
365 | %pre |
---|
366 | getent group zabbix >/dev/null || groupadd -r zabbix |
---|
367 | getent passwd zabbix >/dev/null || \ |
---|
368 | useradd -r -g zabbix -d %{_sysconfdir}/zabbix -s /sbin/nologin \ |
---|
369 | -c "Zabbix Monitoring Solution" zabbix |
---|
370 | exit 0 |
---|
371 | |
---|
372 | %if %{with server} |
---|
373 | %post server-mysql |
---|
374 | %if %{with systemd} |
---|
375 | %systemd_post zabbix-server-mysql.service |
---|
376 | %else |
---|
377 | /sbin/update-alternatives --install /usr/sbin/zabbix_server \ |
---|
378 | zabbix_server /usr/sbin/zabbix_server.mysql 10 |
---|
379 | %endif |
---|
380 | |
---|
381 | %post server-postgresql |
---|
382 | %if %{with systemd} |
---|
383 | %systemd_post zabbix-server-pgsql.service |
---|
384 | %else |
---|
385 | /sbin/update-alternatives --install /usr/sbin/zabbix_server \ |
---|
386 | zabbix_server /usr/sbin/zabbix_server.pgsql 10 |
---|
387 | /sbin/chkconfig --add zabbix_server |
---|
388 | %endif |
---|
389 | %endif |
---|
390 | |
---|
391 | %if %{with proxy} |
---|
392 | %post proxy-mysql |
---|
393 | %if %{with systemd} |
---|
394 | %systemd_post zabbix-proxy-mysql.service |
---|
395 | %else |
---|
396 | /sbin/update-alternatives --install /usr/sbin/zabbix_proxy \ |
---|
397 | zabbix_proxy /usr/sbin/zabbix_proxy.mysql 10 |
---|
398 | /sbin/chkconfig --add zabbix_proxy |
---|
399 | %endif |
---|
400 | |
---|
401 | %post proxy-postgresql |
---|
402 | %if %{with systemd} |
---|
403 | %systemd_post zabbix-proxy-pgsql.service |
---|
404 | %else |
---|
405 | /sbin/update-alternatives --install /usr/sbin/zabbix_proxy \ |
---|
406 | zabbix_proxy /usr/sbin/zabbix_proxy.pgsql 10 |
---|
407 | /sbin/chkconfig --add zabbix_proxy |
---|
408 | %endif |
---|
409 | %endif |
---|
410 | |
---|
411 | %if %{with agent} |
---|
412 | %post agent |
---|
413 | %if %{with systemd} |
---|
414 | %systemd_post zabbix-agent.service |
---|
415 | %else |
---|
416 | /sbin/chkconfig --add zabbix_agentd |
---|
417 | %endif |
---|
418 | |
---|
419 | %endif |
---|
420 | |
---|
421 | %if %{with server} |
---|
422 | %preun server-mysql |
---|
423 | %if %{with systemd} |
---|
424 | %systemd_preun zabbix-server-mysql.service |
---|
425 | %else |
---|
426 | if [ "$1" -eq 0 -o -x /bin/systemctl ]; then |
---|
427 | /sbin/service zabbix_server stop >/dev/null 2>&1 |
---|
428 | /sbin/chkconfig --del zabbix_server |
---|
429 | /sbin/update-alternatives --remove zabbix_server \ |
---|
430 | /usr/sbin/zabbix_server.mysql |
---|
431 | fi |
---|
432 | %endif |
---|
433 | |
---|
434 | %preun server-postgresql |
---|
435 | %if %{with systemd} |
---|
436 | %systemd_preun zabbix-server-pgysql.service |
---|
437 | %else |
---|
438 | if [ "$1" -eq 0 -o -x /bin/systemctl ]; then |
---|
439 | /sbin/service zabbix_server stop >/dev/null 2>&1 |
---|
440 | /sbin/chkconfig --del zabbix_server |
---|
441 | /sbin/update-alternatives --remove zabbix_server \ |
---|
442 | /usr/sbin/zabbix_server.pgsql |
---|
443 | fi |
---|
444 | %endif |
---|
445 | %endif |
---|
446 | |
---|
447 | %if %{with proxy} |
---|
448 | %preun proxy-mysql |
---|
449 | %if %{with systemd} |
---|
450 | %systemd_preun zabbix-proxy-mysql.service |
---|
451 | %else |
---|
452 | if [ "$1" -eq 0 -o -x /bin/systemctl ]; then |
---|
453 | /sbin/service zabbix_proxy stop >/dev/null 2>&1 |
---|
454 | /sbin/chkconfig --del zabbix_proxy |
---|
455 | /sbin/update-alternatives --remove zabbix_proxy \ |
---|
456 | /usr/sbin/zabbix_proxy.mysql |
---|
457 | fi |
---|
458 | %endif |
---|
459 | |
---|
460 | %preun proxy-postgresql |
---|
461 | %if %{with systemd} |
---|
462 | %systemd_preun zabbix-proxy-pgsql.service |
---|
463 | %else |
---|
464 | if [ "$1" -eq 0 -o -x /bin/systemctl ]; then |
---|
465 | /sbin/service zabbix_proxy stop >/dev/null 2>&1 |
---|
466 | /sbin/chkconfig --del zabbix_proxy |
---|
467 | /sbin/update-alternatives --remove zabbix_proxy \ |
---|
468 | /usr/sbin/zabbix_proxy.pgsql |
---|
469 | fi |
---|
470 | %endif |
---|
471 | %endif |
---|
472 | |
---|
473 | %if %{with agent} |
---|
474 | %preun agent |
---|
475 | %if %{with systemd} |
---|
476 | %systemd_preun zabbix-agent.service |
---|
477 | %else |
---|
478 | if [ "$1" -eq 0 -o -x /bin/systemctl ]; then |
---|
479 | /sbin/service zabbix_agentd stop >/dev/null 2>&1 |
---|
480 | /sbin/chkconfig --del zabbix_agentd |
---|
481 | fi |
---|
482 | %endif |
---|
483 | %endif |
---|
484 | |
---|
485 | %if %{with server} |
---|
486 | %postun server-mysql |
---|
487 | %if %{with systemd} |
---|
488 | %systemd_postun_with_restart zabbix-server-mysql.service |
---|
489 | %else |
---|
490 | if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then |
---|
491 | /sbin/service zabbix_server condrestart >/dev/null 2>&1 || : |
---|
492 | fi |
---|
493 | %endif |
---|
494 | |
---|
495 | %postun server-postgresql |
---|
496 | %if %{with systemd} |
---|
497 | %systemd_postun_with_restart zabbix-server-pgsql.service |
---|
498 | %else |
---|
499 | if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then |
---|
500 | /sbin/service zabbix_server condrestart >/dev/null 2>&1 || : |
---|
501 | fi |
---|
502 | %endif |
---|
503 | %endif |
---|
504 | |
---|
505 | %if %{with proxy} |
---|
506 | %postun proxy-mysql |
---|
507 | %if %{with systemd} |
---|
508 | %systemd_postun_with_restart zabbix-proxy-mysql.service |
---|
509 | %else |
---|
510 | if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then |
---|
511 | /sbin/service zabbix_proxy condrestart >/dev/null 2>&1 || : |
---|
512 | fi |
---|
513 | %endif |
---|
514 | |
---|
515 | %postun proxy-postgresql |
---|
516 | %if %{with systemd} |
---|
517 | %systemd_postun_with_restart zabbix-proxy-pgsql.service |
---|
518 | %else |
---|
519 | if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then |
---|
520 | /sbin/service zabbix_proxy condrestart >/dev/null 2>&1 || : |
---|
521 | fi |
---|
522 | %endif |
---|
523 | |
---|
524 | %postun agent |
---|
525 | %if %{with systemd} |
---|
526 | %systemd_postun_with_restart zabbix-agent.service |
---|
527 | %else |
---|
528 | if [ "$1" -ge "1" -a ! -x /bin/systemctl ]; then |
---|
529 | /sbin/service zabbix_agentd condrestart >/dev/null 2>&1 || : |
---|
530 | fi |
---|
531 | %endif |
---|
532 | |
---|
533 | %endif |
---|
534 | |
---|
535 | |
---|
536 | %files |
---|
537 | %defattr(-,root,root,-) |
---|
538 | %license zabbix_mysql/COPYING |
---|
539 | %doc zabbix_mysql/AUTHORS zabbix_mysql/ChangeLog zabbix_mysql/NEWS zabbix_mysql/README |
---|
540 | %attr(0755,zabbix,zabbix) %dir %{_localstatedir}/log/%{name} |
---|
541 | %dir %{_datadir}/zabbix |
---|
542 | %if %{with server}%{with proxy} |
---|
543 | %{_datadir}/zabbix/mysql |
---|
544 | %{_datadir}/zabbix/postgresql |
---|
545 | %endif |
---|
546 | %if %{with systemd} |
---|
547 | %{_prefix}/lib/tmpfiles.d/zabbix.conf |
---|
548 | %endif |
---|
549 | %{_bindir}/zabbix_js |
---|
550 | |
---|
551 | %if %{with server} |
---|
552 | %files server-common |
---|
553 | %defattr(-,root,root,-) |
---|
554 | %dir %{_sysconfdir}/zabbix |
---|
555 | %config(noreplace) %{_sysconfdir}/zabbix/zabbix_server.conf |
---|
556 | %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix_server |
---|
557 | %if !%{with systemd} |
---|
558 | %{_initddir}/zabbix_server* |
---|
559 | %endif |
---|
560 | %{_mandir}/man8/zabbix_server.8* |
---|
561 | |
---|
562 | %files server-mysql |
---|
563 | %defattr(-,root,root,-) |
---|
564 | %{_sbindir}/zabbix_server.mysql |
---|
565 | %if %{with systemd} |
---|
566 | %{_unitdir}/zabbix-server-mysql.service |
---|
567 | %endif |
---|
568 | |
---|
569 | %files server-postgresql |
---|
570 | %defattr(-,root,root,-) |
---|
571 | %{_sbindir}/zabbix_server.pgsql |
---|
572 | %if %{with systemd} |
---|
573 | %{_unitdir}/zabbix-server-pgsql.service |
---|
574 | %endif |
---|
575 | |
---|
576 | %endif |
---|
577 | |
---|
578 | %if %{with agent} |
---|
579 | %files agent |
---|
580 | %defattr(-,root,root,-) |
---|
581 | %dir %{_sysconfdir}/zabbix |
---|
582 | %config(noreplace) %{_sysconfdir}/zabbix/zabbix_agentd.conf |
---|
583 | %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix_agentd |
---|
584 | %{_bindir}/zabbix_get |
---|
585 | %{_bindir}/zabbix_sender |
---|
586 | %{_sbindir}/zabbix_agentd |
---|
587 | %if %{with systemd} |
---|
588 | %{_unitdir}/zabbix-agent.service |
---|
589 | %else |
---|
590 | %{_initddir}/zabbix_agentd |
---|
591 | %endif |
---|
592 | %{_mandir}/man1/zabbix_get.1* |
---|
593 | %{_mandir}/man1/zabbix_sender.1* |
---|
594 | %{_mandir}/man8/zabbix_agentd.8* |
---|
595 | |
---|
596 | %endif |
---|
597 | |
---|
598 | %if %{with proxy} |
---|
599 | %files proxy-common |
---|
600 | %defattr(-,root,root,-) |
---|
601 | %dir %{_sysconfdir}/zabbix |
---|
602 | %config(noreplace) %{_sysconfdir}/zabbix/zabbix_proxy.conf |
---|
603 | %config(noreplace) %{_sysconfdir}/logrotate.d/zabbix_proxy |
---|
604 | %if !%{with systemd} |
---|
605 | %{_initddir}/zabbix_proxy |
---|
606 | %endif |
---|
607 | %{_mandir}/man8/zabbix_proxy.8* |
---|
608 | %{_datadir}/zabbix-proxy |
---|
609 | |
---|
610 | %files proxy-mysql |
---|
611 | %defattr(-,root,root,-) |
---|
612 | %{_sbindir}/zabbix_proxy.mysql |
---|
613 | %if %{with systemd} |
---|
614 | %{_unitdir}/zabbix-proxy-mysql.service |
---|
615 | %endif |
---|
616 | |
---|
617 | %files proxy-postgresql |
---|
618 | %defattr(-,root,root,-) |
---|
619 | %{_sbindir}/zabbix_proxy.pgsql |
---|
620 | %if %{with systemd} |
---|
621 | %{_unitdir}/zabbix-proxy-pgsql.service |
---|
622 | %endif |
---|
623 | |
---|
624 | %endif |
---|
625 | |
---|
626 | %if %{with frontend} |
---|
627 | %files frontend-php |
---|
628 | %defattr(-,root,root,-) |
---|
629 | %license zabbix_mysql/COPYING |
---|
630 | %doc zabbix_mysql/AUTHORS zabbix_mysql/ChangeLog zabbix_mysql/NEWS zabbix_mysql/README |
---|
631 | %dir %{_datadir}/zabbix-frontend |
---|
632 | %{_datadir}/zabbix-frontend/php |
---|
633 | |
---|
634 | %files frontend-php-mysql |
---|
635 | |
---|
636 | %files frontend-php-postgresql |
---|
637 | |
---|
638 | %endif |
---|
639 | |
---|
640 | |
---|
641 | %changelog |
---|
642 | * Tue Sep 08 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.0.3-1 |
---|
643 | - new upstream release. |
---|
644 | |
---|
645 | * Thu Jul 23 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.0.2-1 |
---|
646 | - new upstream release. |
---|
647 | - dropped all patches: made to get the same effect by another method. |
---|
648 | |
---|
649 | * Wed Apr 15 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.19-2 |
---|
650 | - rebuilt with libevent-2.1.11. |
---|
651 | |
---|
652 | * Mon Apr 06 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.19-1 |
---|
653 | - new upstream release. |
---|
654 | - dropped Patch3: fixed in upstream. |
---|
655 | - changed R:php5 to R:php74. |
---|
656 | - added systemd support (disabled as default). |
---|
657 | |
---|
658 | * Thu Dec 19 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.15-1 |
---|
659 | - new upstream release. |
---|
660 | - imported Patch13 from upstream to support php74. |
---|
661 | |
---|
662 | * Thu Oct 17 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.13-1 |
---|
663 | - new upstream release. |
---|
664 | - updated patches. |
---|
665 | |
---|
666 | * Wed May 08 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.0.7-1 |
---|
667 | - new upstream release. |
---|
668 | - switched to 4.0 LTS. |
---|
669 | - dropped Patch0: made to get same effect by another method. |
---|
670 | - updated Patch1 and 2. |
---|
671 | |
---|
672 | * Wed Nov 07 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.0.23-1 |
---|
673 | - new upstream release. |
---|
674 | |
---|
675 | * Tue Jun 12 2018 IWAI, Masaharu <iwaim.sub@gmail.com> 3.0.13-2 |
---|
676 | - accept building only agent |
---|
677 | |
---|
678 | * Thu Dec 21 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.0.13-1 |
---|
679 | - new upstream release. |
---|
680 | |
---|
681 | * Fri Apr 21 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.0.8-1 |
---|
682 | - new upstream release. |
---|
683 | |
---|
684 | * Fri Mar 18 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.0.1-1 |
---|
685 | - new upstream release. |
---|
686 | - disabled jabber support. |
---|
687 | |
---|
688 | * Wed Sep 9 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.4.6-1 |
---|
689 | - new upstream release. |
---|
690 | |
---|
691 | * Sat Apr 11 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.2.9-1 |
---|
692 | - new upstream release. |
---|
693 | |
---|
694 | * Sun Jul 6 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.2.4-1 |
---|
695 | - new upstream release. |
---|
696 | - built with both of mysql and postgresql. |
---|
697 | |
---|
698 | * Mon Oct 07 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 2.0.8-1 |
---|
699 | - update to 2.0.8 |
---|
700 | |
---|
701 | * Wed Feb 20 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 2.0.5-2 |
---|
702 | - use %%bcond_with mysql to build with mysql |
---|
703 | |
---|
704 | * Tue Feb 19 2013 IWAI, Masaharu <iwai@alib.jp> 2.0.5-1 |
---|
705 | - update to 2.0.5 |
---|
706 | - add using MySQL client library switch: default no |
---|
707 | - define use_postfix and use_mysql |
---|
708 | - add BuildRequires: MySQL-devel |
---|
709 | - add configure option: --with-mysql |
---|
710 | |
---|
711 | * Thu Feb 7 2013 IWAI, Masaharu <iwai@alib.jp> 2.0.4-1 |
---|
712 | - initial build for Vine Linux |
---|