]> granicus.if.org Git - icinga2/blob - icinga2.spec
Release version 2.4.5
[icinga2] / icinga2.spec
1 #/******************************************************************************
2 # * Icinga 2                                                                   *
3 # * Copyright (C) 2012-2016 Icinga Development Team (https://www.icinga.org/)  *
4 # *                                                                            *
5 # * This program is free software; you can redistribute it and/or              *
6 # * modify it under the terms of the GNU General Public License                *
7 # * as published by the Free Software Foundation; either version 2             *
8 # * of the License, or (at your option) any later version.                     *
9 # *                                                                            *
10 # * This program is distributed in the hope that it will be useful,            *
11 # * but WITHOUT ANY WARRANTY; without even the implied warranty of             *
12 # * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              *
13 # * GNU General Public License for more details.                               *
14 # *                                                                            *
15 # * You should have received a copy of the GNU General Public License          *
16 # * along with this program; if not, write to the Free Software Foundation     *
17 # * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.             *
18 # ******************************************************************************/
19
20 %define revision 1
21
22 # make sure that _rundir is working on older systems
23 %if ! %{defined _rundir}
24 %define _rundir %{_localstatedir}/run
25 %endif
26
27 %define _libexecdir %{_prefix}/lib/
28
29 %if "%{_vendor}" == "redhat"
30 %define apachename httpd
31 %define apacheconfdir %{_sysconfdir}/httpd/conf.d
32 %define apacheuser apache
33 %define apachegroup apache
34 %if 0%{?el5}%{?el6}
35 %define use_systemd 0
36 %if %(uname -m) != "x86_64"
37 %define march_flag -march=i686
38 %endif
39 %else
40 # fedora and el>=7
41 %define use_systemd 1
42 %endif
43 %endif
44
45 %if "%{_vendor}" == "suse"
46 %define apachename apache2
47 %define apacheconfdir  %{_sysconfdir}/apache2/conf.d
48 %define apacheuser wwwrun
49 %define apachegroup www
50 %if 0%{?suse_version} >= 1310
51 %define use_systemd 1
52 %else
53 %define use_systemd 0
54 %endif
55 %endif
56
57 %define icinga_user icinga
58 %define icinga_group icinga
59 %define icingacmd_group icingacmd
60 %define icingaweb2name icingaweb2
61 %define icingaweb2version 2.0.0
62
63 %define icingaclassicconfdir %{_sysconfdir}/icinga
64
65 %define logmsg logger -t %{name}/rpm
66
67 Summary: Network monitoring application
68 Name: icinga2
69 Version: 2.4.5
70 Release: %{revision}%{?dist}
71 License: GPL-2.0+
72 Group: Applications/System
73 Source: https://github.com/Icinga/%{name}/archive/v%{version}.tar.gz
74 URL: https://www.icinga.org/
75 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
76 Requires: %{name}-bin = %{version}-%{release}
77
78 %description
79 Meta package for Icinga 2 Core, DB IDO and Web.
80
81 %package bin
82 Summary:      Icinga 2 binaries and libraries
83 Group:        Applications/System
84
85 %if "%{_vendor}" == "suse"
86 PreReq:        permissions
87 Provides:      monitoring_daemon
88 Recommends:    monitoring-plugins
89 %if 0%{?suse_version} >= 1310
90 BuildRequires: libyajl-devel
91 %endif
92 %endif
93 BuildRequires: libedit-devel
94 BuildRequires: ncurses-devel
95 %if "%{_vendor}" == "suse" && 0%{?suse_version} < 1210
96 BuildRequires: gcc48-c++
97 BuildRequires: libstdc++47-devel
98 BuildRequires: libopenssl1-devel
99 %else
100 BuildRequires: gcc-c++
101 BuildRequires: libstdc++-devel
102 BuildRequires: openssl-devel
103 %endif
104 BuildRequires: cmake
105 BuildRequires: flex >= 2.5.35
106 BuildRequires: bison
107 BuildRequires: make
108
109 %if 0%{?build_icinga_org} && "%{_vendor}" == "redhat" && (0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
110 # el5 and el6 require packages.icinga.org
111 BuildRequires: boost153-devel
112 %else
113 %if 0%{?build_icinga_org} && "%{_vendor}" == "suse" && 0%{?suse_version} < 1310
114 # sles 11 sp3 requires packages.icinga.org
115 BuildRequires: boost153-devel
116 %else
117 BuildRequires: boost-devel >= 1.41
118 %endif
119 %endif
120
121 %if 0%{?use_systemd}
122 BuildRequires: systemd
123 Requires: systemd
124 %endif
125
126 Requires: %{name}-common = %{version}-%{release}
127
128 %description bin
129 Icinga 2 is a general-purpose network monitoring application.
130 Provides binaries and libraries for Icinga 2 Core.
131
132 %package common
133 Summary:      Common Icinga 2 configuration
134 Group:        Applications/System
135 %if "%{_vendor}" == "redhat"
136 Requires(pre): shadow-utils
137 Requires(post): shadow-utils
138 %endif
139 %if "%{_vendor}" == "suse"
140 Recommends:   logrotate
141 %endif
142
143 %description common
144 Provides common directories, uid and gid among Icinga 2 related
145 packages.
146
147
148 %package doc
149 Summary:      Documentation for Icinga 2
150 Group:        Applications/System
151 Requires:     %{name} = %{version}-%{release}
152
153 %description doc
154 Provides documentation for Icinga 2.
155
156
157 %package ido-mysql
158 Summary:      IDO MySQL database backend for Icinga 2
159 Group:        Applications/System
160 %if "%{_vendor}" == "suse"
161 BuildRequires: libmysqlclient-devel
162 %if 0%{?suse_version} >= 1310
163 BuildRequires: mysql-devel
164 %endif
165
166 %else
167 BuildRequires: mysql-devel
168 %endif #suse
169
170 Requires: %{name} = %{version}-%{release}
171
172 %description ido-mysql
173 Icinga 2 IDO mysql database backend. Compatible with Icinga 1.x
174 IDOUtils schema >= 1.12
175
176
177 %package ido-pgsql
178 Summary:      IDO PostgreSQL database backend for Icinga 2
179 Group:        Applications/System
180 BuildRequires: postgresql-devel
181 Requires: %{name} = %{version}-%{release}
182
183 %description ido-pgsql
184 Icinga 2 IDO PostgreSQL database backend. Compatible with Icinga 1.x
185 IDOUtils schema >= 1.12
186
187
188 %package classicui-config
189 Summary:      Icinga 2 Classic UI Standalone configuration
190 Group:        Applications/System
191 BuildRequires: %{apachename}
192 Requires:     %{apachename}
193 Requires:     %{name} = %{version}-%{release}
194 %if "%{_vendor}" == "suse"
195 Recommends:   icinga-www
196 %endif
197 Provides:     icinga-classicui-config
198 Conflicts:    icinga-gui-config
199
200 %description classicui-config
201 Icinga 1.x Classic UI Standalone configuration with locations
202 for Icinga 2.
203
204 %if "%{_vendor}" == "redhat" && !(0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
205 %global selinux_variants mls targeted
206 %{!?_selinux_policy_version: %global _selinux_policy_version %(sed -e 's,.*selinux-policy-\\([^/]*\\)/.*,\\1,' /usr/share/selinux/devel/policyhelp 2>/dev/null)}
207 %global modulename %{name}
208
209 %package selinux
210 Summary:        SELinux policy module supporting icinga2
211 Group:          System Environment/Base
212 BuildRequires:  checkpolicy, selinux-policy-devel, /usr/share/selinux/devel/policyhelp, hardlink
213 %if "%{_selinux_policy_version}" != ""
214 Requires:       selinux-policy >= %{_selinux_policy_version}
215 %endif
216 Requires:       %{name} = %{version}-%{release}
217 Requires(post):   /usr/sbin/semodule, /sbin/restorecon
218 Requires(postun): /usr/sbin/semodule, /sbin/restorecon
219
220 %description selinux
221 SELinux policy module supporting icinga2
222 %endif
223
224
225 %prep
226 %setup -q -n %{name}-%{version}
227
228 %build
229 CMAKE_OPTS="-DCMAKE_INSTALL_PREFIX=/usr \
230          -DCMAKE_INSTALL_SYSCONFDIR=/etc \
231          -DCMAKE_INSTALL_LOCALSTATEDIR=/var \
232          -DCMAKE_BUILD_TYPE=RelWithDebInfo \
233          -DCMAKE_VERBOSE_MAKEFILE=ON \
234          -DBoost_NO_BOOST_CMAKE=ON \
235          -DICINGA2_RUNDIR=%{_rundir} \
236          -DICINGA2_USER=%{icinga_user} \
237          -DICINGA2_GROUP=%{icinga_group} \
238          -DICINGA2_COMMAND_GROUP=%{icingacmd_group}"
239 %if "%{_vendor}" == "redhat"
240 %if 0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6"
241 # Boost_VERSION 1.41.0 vs 101400 - disable build tests
242 # details in https://dev.icinga.org/issues/5033
243 CMAKE_OPTS="$CMAKE_OPTS -DBOOST_LIBRARYDIR=/usr/lib/boost153 \
244  -DBOOST_INCLUDEDIR=/usr/include/boost153 \
245  -DBoost_ADDITIONAL_VERSIONS='1.53;1.53.0' \
246  -DBoost_NO_SYSTEM_PATHS=TRUE \
247  -DBUILD_TESTING=FALSE \
248  -DBoost_NO_BOOST_CMAKE=TRUE"
249 %endif
250 %if 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6"
251 CMAKE_OPTS="$CMAKE_OPTS -DBUILD_TESTING=FALSE"
252 %endif
253 %endif
254
255 %if "%{_vendor}" != "suse"
256 CMAKE_OPTS="$CMAKE_OPTS -DICINGA2_PLUGINDIR=%{_libdir}/nagios/plugins"
257 %else
258 %if 0%{?suse_version} < 1310
259 CMAKE_OPTS="$CMAKE_OPTS -DBOOST_LIBRARYDIR=/usr/lib/boost153 \
260  -DBOOST_INCLUDEDIR=/usr/include/boost153 \
261  -DBoost_ADDITIONAL_VERSIONS='1.53;1.53.0' \
262  -DBoost_NO_SYSTEM_PATHS=TRUE \
263  -DBUILD_TESTING=FALSE \
264  -DBoost_NO_BOOST_CMAKE=TRUE"
265 %endif
266 CMAKE_OPTS="$CMAKE_OPTS -DICINGA2_PLUGINDIR=%{_prefix}/lib/nagios/plugins"
267 %endif
268
269 %if 0%{?use_systemd}
270 CMAKE_OPTS="$CMAKE_OPTS -DUSE_SYSTEMD=ON"
271 %endif
272
273 cmake $CMAKE_OPTS -DCMAKE_C_FLAGS:STRING="%{optflags} %{?march_flag}" -DCMAKE_CXX_FLAGS:STRING="%{optflags} %{?march_flag}" .
274
275 make %{?_smp_mflags}
276
277 %if "%{_vendor}" == "redhat" && !(0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
278 cd tools/selinux
279 for selinuxvariant in %{selinux_variants}
280 do
281   make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile
282   mv %{modulename}.pp %{modulename}.pp.${selinuxvariant}
283   make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile clean
284 done
285 cd -
286 %endif
287
288 %install
289 make install \
290         DESTDIR="%{buildroot}"
291
292 # install classicui config
293 install -D -m 0644 etc/icinga/icinga-classic.htpasswd %{buildroot}%{icingaclassicconfdir}/passwd
294 install -D -m 0644 etc/icinga/cgi.cfg %{buildroot}%{icingaclassicconfdir}/cgi.cfg
295 install -D -m 0644 etc/icinga/icinga-classic-apache.conf %{buildroot}%{apacheconfdir}/icinga.conf
296
297 # remove features-enabled symlinks
298 rm -f %{buildroot}/%{_sysconfdir}/%{name}/features-enabled/*.conf
299
300 # enable suse rc links
301 %if "%{_vendor}" == "suse"
302 %if 0%{?use_systemd}
303   ln -sf /usr/sbin/service %{buildroot}%{_sbindir}/rc%{name}
304 %else
305   ln -sf ../../%{_initrddir}/%{name} "%{buildroot}%{_sbindir}/rc%{name}"
306 %endif
307 mkdir -p "%{buildroot}%{_localstatedir}/adm/fillup-templates/"
308 mv "%{buildroot}%{_sysconfdir}/sysconfig/%{name}" "%{buildroot}%{_localstatedir}/adm/fillup-templates/sysconfig.%{name}"
309 %endif
310
311 %if "%{_vendor}" == "redhat" && !(0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
312 cd tools/selinux
313 for selinuxvariant in %{selinux_variants}
314 do
315   install -d %{buildroot}%{_datadir}/selinux/${selinuxvariant}
316   install -p -m 644 %{modulename}.pp.${selinuxvariant} \
317     %{buildroot}%{_datadir}/selinux/${selinuxvariant}/%{modulename}.pp
318 done
319 cd -
320
321 /usr/sbin/hardlink -cv %{buildroot}%{_datadir}/selinux
322 %endif
323
324 %clean
325 [ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot}
326
327 %pre common
328 getent group %{icinga_group} >/dev/null || %{_sbindir}/groupadd -r %{icinga_group}
329 getent group %{icingacmd_group} >/dev/null || %{_sbindir}/groupadd -r %{icingacmd_group}
330 getent passwd %{icinga_user} >/dev/null || %{_sbindir}/useradd -c "icinga" -s /sbin/nologin -r -d %{_localstatedir}/spool/%{name} -G %{icingacmd_group} -g %{icinga_group} %{icinga_user}
331
332 %if "%{_vendor}" == "suse"
333 %if 0%{?use_systemd}
334   %service_add_pre %{name}.service
335 %endif
336 %endif
337
338 %if "%{_vendor}" == "suse"
339 %verifyscript bin
340 %verify_permissions -e %{_rundir}/%{name}/cmd
341 %endif
342
343 %post bin
344
345 # suse
346 %if "%{_vendor}" == "suse"
347
348 %if 0%{?suse_version} >= 1310
349 %set_permissions %{_rundir}/%{name}/cmd
350 %endif
351
352 %endif #suse/rhel
353
354 %post common
355 # suse
356 %if "%{_vendor}" == "suse"
357 %if 0%{?use_systemd}
358 %fillup_only  %{name}
359 %service_add_post %{name}.service
360 %else
361 %fillup_and_insserv %{name}
362 %endif
363
364 # initial installation, enable default features
365 for feature in checker notification mainlog; do
366         ln -sf ../features-available/${feature}.conf %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
367 done
368
369 exit 0
370
371 %else
372 # rhel
373
374 %if 0%{?use_systemd}
375 %systemd_post %{name}.service
376 %else
377 /sbin/chkconfig --add %{name}
378 %endif
379
380 if [ ${1:-0} -eq 1 ]
381 then
382         # initial installation, enable default features
383         for feature in checker notification mainlog; do
384                 ln -sf ../features-available/${feature}.conf %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
385         done
386 fi
387
388 exit 0
389
390 %endif
391 # suse/rhel
392
393 %postun common
394 # suse
395 %if "%{_vendor}" == "suse"
396 %if 0%{?using_systemd}
397   %service_del_postun %{name}.service
398 %else
399   %restart_on_update %{name}
400   %insserv_cleanup
401 %endif
402
403 %else
404 # rhel
405
406 %if 0%{?use_systemd}
407 %systemd_postun_with_restart %{name}.service
408 %else
409 if [ "$1" -ge  "1" ]; then
410         /sbin/service %{name} condrestart >/dev/null 2>&1 || :
411 fi
412 %endif
413
414 %endif
415 # suse / rhel
416
417 if [ "$1" = "0" ]; then
418         # deinstallation of the package - remove enabled features
419         rm -rf %{_sysconfdir}/%{name}/features-enabled
420 fi
421
422 exit 0
423
424 %preun common
425 # suse
426 %if "%{_vendor}" == "suse"
427
428 %if 0%{?use_systemd}
429   %service_del_preun %{name}.service
430 %else
431   %stop_on_removal %{name}
432 %endif
433
434 exit 0
435
436 %else
437 # rhel
438
439 %if 0%{?use_systemd}
440 %systemd_preun %{name}.service
441 %else
442 if [ "$1" = "0" ]; then
443         /sbin/service %{name} stop > /dev/null 2>&1 || :
444         /sbin/chkconfig --del %{name} || :
445 fi
446 %endif
447
448 exit 0
449
450 %endif
451 # suse / rhel
452
453 %post ido-mysql
454 if [ ${1:-0} -eq 1 ]
455 then
456         # initial installation, enable ido-mysql feature
457         ln -sf ../features-available/ido-mysql.conf %{_sysconfdir}/%{name}/features-enabled/ido-mysql.conf
458 fi
459
460 exit 0
461
462 %postun ido-mysql
463 if [ "$1" = "0" ]; then
464         # deinstallation of the package - remove feature
465         rm -f %{_sysconfdir}/%{name}/features-enabled/ido-mysql.conf
466 fi
467
468 exit 0
469
470 %post ido-pgsql
471 if [ ${1:-0} -eq 1 ]
472 then
473         # initial installation, enable ido-pgsql feature
474         ln -sf ../features-available/ido-pgsql.conf %{_sysconfdir}/%{name}/features-enabled/ido-pgsql.conf
475 fi
476
477 exit 0
478
479 %postun ido-pgsql
480 if [ "$1" = "0" ]; then
481         # deinstallation of the package - remove feature
482         rm -f %{_sysconfdir}/%{name}/features-enabled/ido-pgsql.conf
483 fi
484
485 exit 0
486
487 %post classicui-config
488 if [ ${1:-0} -eq 1 ]
489 then
490         # initial installation, enable features
491         for feature in statusdata compatlog command; do
492                 ln -sf ../features-available/${feature}.conf %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
493         done
494 fi
495
496 exit 0
497
498 %postun classicui-config
499 if [ "$1" = "0" ]; then
500         # deinstallation of the package - remove feature
501         for feature in statusdata compatlog command; do
502                 rm -f %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
503         done
504 fi
505
506 exit 0
507
508 %if "%{_vendor}" == "redhat" && !(0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
509 %post selinux
510 for selinuxvariant in %{selinux_variants}
511 do
512   /usr/sbin/semodule -s ${selinuxvariant} -i \
513     %{_datadir}/selinux/${selinuxvariant}/%{modulename}.pp &> /dev/null || :
514 done
515 /sbin/fixfiles -R icinga2-bin restore &> /dev/null || :
516 /sbin/fixfiles -R icinga2-common restore &> /dev/null || :
517 /sbin/semanage port -a -t icinga2_port_t -p tcp 5665 &> /dev/null || :
518
519 %postun selinux
520 if [ $1 -eq 0 ] ; then
521   /sbin/semanage port -d -t icinga2_port_t -p tcp 5665 &> /dev/null || :
522   for selinuxvariant in %{selinux_variants}
523   do
524      /usr/sbin/semodule -s ${selinuxvariant} -r %{modulename} &> /dev/null || :
525   done
526   /sbin/fixfiles -R icinga2-bin restore &> /dev/null || :
527   /sbin/fixfiles -R icinga2-common restore &> /dev/null || :
528 fi
529 %endif
530
531
532 %files
533 %defattr(-,root,root,-)
534 %doc COPYING
535
536 %files bin
537 %defattr(-,root,root,-)
538 %doc COPYING COPYING.Exceptions README.md NEWS AUTHORS ChangeLog
539 %{_sbindir}/%{name}
540 %exclude %{_libdir}/%{name}/libdb_ido_mysql*
541 %exclude %{_libdir}/%{name}/libdb_ido_pgsql*
542 %dir %{_libdir}/%{name}
543 %{_libdir}/%{name}/*.so*
544 %dir %{_libdir}/%{name}/sbin
545 %{_libdir}/%{name}/sbin/%{name}
546 %{_datadir}/%{name}
547 %exclude %{_datadir}/%{name}/include
548 %{_mandir}/man8/%{name}.8.gz
549
550 %attr(0750,%{icinga_user},%{icingacmd_group}) %{_localstatedir}/cache/%{name}
551 %attr(0750,%{icinga_user},%{icingacmd_group}) %dir %{_localstatedir}/log/%{name}
552 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_localstatedir}/log/%{name}/crash
553 %attr(0750,%{icinga_user},%{icingacmd_group}) %dir %{_localstatedir}/log/%{name}/compat
554 %attr(0750,%{icinga_user},%{icingacmd_group}) %dir %{_localstatedir}/log/%{name}/compat/archives
555 %attr(0750,%{icinga_user},%{icinga_group}) %{_localstatedir}/lib/%{name}
556
557 %attr(0750,%{icinga_user},%{icingacmd_group}) %ghost %{_rundir}/%{name}
558 %attr(2750,%{icinga_user},%{icingacmd_group}) %ghost %{_rundir}/%{name}/cmd
559
560 %files common
561 %defattr(-,root,root,-)
562 %doc COPYING COPYING.Exceptions README.md NEWS AUTHORS ChangeLog tools/syntax
563 %attr(0750,%{icinga_user},%{icingacmd_group}) %dir %{_localstatedir}/log/%{name}
564 %config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
565 %{_sysconfdir}/bash_completion.d/%{name}
566 %if 0%{?use_systemd}
567 %attr(644,root,root) %{_unitdir}/%{name}.service
568 %else
569 %attr(755,root,root) %{_sysconfdir}/init.d/%{name}
570 %endif
571 %if "%{_vendor}" == "suse"
572 %{_sbindir}/rc%{name}
573 %{_localstatedir}/adm/fillup-templates/sysconfig.%{name}
574 %else
575 %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
576 %endif
577 %attr(0750,root,%{icinga_group}) %dir %{_sysconfdir}/%{name}
578 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/conf.d
579 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/features-available
580 %exclude %{_sysconfdir}/%{name}/features-available/ido-*.conf
581 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/features-enabled
582 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/repository.d
583 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/scripts
584 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/repository.d
585 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_sysconfdir}/%{name}/zones.d
586 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/%{name}.conf
587 %config(noreplace) %attr(0640,root,%{icinga_group}) %{_sysconfdir}/%{name}/init.conf
588 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/constants.conf
589 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/zones.conf
590 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/conf.d/*.conf
591 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/features-available/*.conf
592 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/repository.d/*
593 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/zones.d/*
594 %config(noreplace) %{_sysconfdir}/%{name}/scripts/*
595 %dir %{_libexecdir}/%{name}
596 %{_libexecdir}/%{name}/prepare-dirs
597 %{_libexecdir}/%{name}/safe-reload
598 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_localstatedir}/spool/%{name}
599 %attr(0770,%{icinga_user},%{icinga_group}) %dir %{_localstatedir}/spool/%{name}/perfdata
600 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_localstatedir}/spool/%{name}/tmp
601 %attr(0750,%{icinga_user},%{icinga_group}) %dir %{_datadir}/%{name}/include
602 %{_datadir}/%{name}/include
603
604 %files doc
605 %defattr(-,root,root,-)
606 %{_datadir}/doc/%{name}
607 %docdir %{_datadir}/doc/%{name}
608
609 %files ido-mysql
610 %defattr(-,root,root,-)
611 %doc COPYING COPYING.Exceptions README.md NEWS AUTHORS ChangeLog
612 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/features-available/ido-mysql.conf
613 %{_libdir}/%{name}/libdb_ido_mysql*
614 %{_datadir}/icinga2-ido-mysql
615
616 %files ido-pgsql
617 %defattr(-,root,root,-)
618 %doc COPYING COPYING.Exceptions README.md NEWS AUTHORS ChangeLog
619 %config(noreplace) %attr(0640,%{icinga_user},%{icinga_group}) %{_sysconfdir}/%{name}/features-available/ido-pgsql.conf
620 %{_libdir}/%{name}/libdb_ido_pgsql*
621 %{_datadir}/icinga2-ido-pgsql
622
623 %files classicui-config
624 %defattr(-,root,root,-)
625 %attr(0751,%{icinga_user},%{icinga_group}) %dir %{icingaclassicconfdir}
626 %config(noreplace) %{icingaclassicconfdir}/cgi.cfg
627 %config(noreplace) %{apacheconfdir}/icinga.conf
628 %config(noreplace) %attr(0640,root,%{apachegroup}) %{icingaclassicconfdir}/passwd
629
630 %if "%{_vendor}" == "redhat" && !(0%{?el5} || 0%{?rhel} == 5 || "%{?dist}" == ".el5" || 0%{?el6} || 0%{?rhel} == 6 || "%{?dist}" == ".el6")
631 %files selinux
632 %defattr(-,root,root,0755)
633 %doc tools/selinux/*
634 %{_datadir}/selinux/*/%{modulename}.pp
635 %endif
636
637 %changelog