parent
51b7b89129
commit
ac318251c7
|
@ -5,12 +5,10 @@
|
||||||
|
|
||||||
%define revision 0
|
%define revision 0
|
||||||
|
|
||||||
# FIXME logdir must be set to /var/log/icingaweb
|
%define configdir %{_sysconfdir}/icingaweb
|
||||||
#%define logdir %{_localstatedir}/log/%{name}
|
%define logdir %{_localstatedir}/log/icingaweb
|
||||||
%define logdir %{_datadir}/icingaweb/var/log
|
|
||||||
%define sharedir %{_datadir}/icingaweb
|
%define sharedir %{_datadir}/icingaweb
|
||||||
%define prefixdir %{_datadir}/icingaweb
|
%define prefixdir %{_datadir}/icingaweb
|
||||||
%define configdir %{_sysconfdir}/icingaweb
|
|
||||||
|
|
||||||
%if "%{_vendor}" == "suse"
|
%if "%{_vendor}" == "suse"
|
||||||
%define phpname php5
|
%define phpname php5
|
||||||
|
@ -30,15 +28,15 @@
|
||||||
%define apacheconfdir %{_sysconfdir}/apache2/conf.d
|
%define apacheconfdir %{_sysconfdir}/apache2/conf.d
|
||||||
%define apacheuser wwwrun
|
%define apacheuser wwwrun
|
||||||
%define apachegroup www
|
%define apachegroup www
|
||||||
%define extcmdfile-1x %{_localstatedir}/icinga/rw/icinga.cmd
|
%define extcmdfile1x %{_localstatedir}/icinga/rw/icinga.cmd
|
||||||
%define livestatussocket-1x %{_localstatedir}/icinga/rw/live
|
%define livestatussocket1x %{_localstatedir}/icinga/rw/live
|
||||||
%endif
|
%endif
|
||||||
%if "%{_vendor}" == "redhat"
|
%if "%{_vendor}" == "redhat"
|
||||||
%define apacheconfdir %{_sysconfdir}/httpd/conf.d
|
%define apacheconfdir %{_sysconfdir}/httpd/conf.d
|
||||||
%define apacheuser apache
|
%define apacheuser apache
|
||||||
%define apachegroup apache
|
%define apachegroup apache
|
||||||
%define extcmdfile-1x %{_localstatedir}/spool/icinga/cmd/icinga.cmd
|
%define extcmdfile-1x %{_localstatedir}/spool/icinga/cmd/icinga.cmd
|
||||||
%define livestatussocket-1x %{_localstatedir}/spool/icinga/cmd/live
|
%define livestatussocket1x %{_localstatedir}/spool/icinga/cmd/live
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
Summary: Open Source host, service and network monitoring Web UI
|
Summary: Open Source host, service and network monitoring Web UI
|
||||||
|
@ -101,15 +99,6 @@ Requires: %{name}-doc
|
||||||
IcingaWeb for Icinga 2 or Icinga 1.x using status data,
|
IcingaWeb for Icinga 2 or Icinga 1.x using status data,
|
||||||
IDOUtils or Livestatus as backend provider.
|
IDOUtils or Livestatus as backend provider.
|
||||||
|
|
||||||
%package doc
|
|
||||||
Summary: documentation for IcingaWeb
|
|
||||||
Group: Applications/System
|
|
||||||
Requires: %{name} = %{version}-%{release}
|
|
||||||
|
|
||||||
|
|
||||||
%description doc
|
|
||||||
Documentation for IcingaWeb.
|
|
||||||
|
|
||||||
%package config-internal-mysql
|
%package config-internal-mysql
|
||||||
Summary: config for internal mysql database
|
Summary: config for internal mysql database
|
||||||
Group: Applications/System
|
Group: Applications/System
|
||||||
|
@ -191,13 +180,28 @@ Icinga 1.x
|
||||||
--datarootdir="%{sharedir}" \
|
--datarootdir="%{sharedir}" \
|
||||||
--sysconfdir="%{configdir}" \
|
--sysconfdir="%{configdir}" \
|
||||||
--with-icingaweb-config-path='%{configdir}' \
|
--with-icingaweb-config-path='%{configdir}' \
|
||||||
|
--with-icingaweb-log-path='%{logdir}' \
|
||||||
--with-web-path='/icingaweb' \
|
--with-web-path='/icingaweb' \
|
||||||
--with-httpd-config-path=%{apacheconfdir} \
|
--with-httpd-config-path=%{apacheconfdir} \
|
||||||
--with-web-user='%{apacheuser}' \
|
--with-web-user='%{apacheuser}' \
|
||||||
--with-web-group='%{apachegroup}' \
|
--with-web-group='%{apachegroup}' \
|
||||||
--with-icinga-commandpipe='%{extcmdfile-1x}' \
|
--with-internal-db-type='mysql' \
|
||||||
--with-livestatus-socket='%{livestatussocket-1x}'
|
--with-internal-db-name='icingaweb' \
|
||||||
# TODO --with-log-dir='%{logdir}'
|
--with-internal-db-host='localhost' \
|
||||||
|
--with-internal-db-port='3306' \
|
||||||
|
--with-internal-db-pass='icingaweb' \
|
||||||
|
--with-internal-db-user='icingaweb' \
|
||||||
|
--with-internal-authentication=yes \
|
||||||
|
--with-icinga-commandpipe='%{extcmdfile1x}' \
|
||||||
|
--with-livestatus-socket='%{livestatussocket1x}'
|
||||||
|
|
||||||
|
cat > README.RHEL.SUSE <<"EOF"
|
||||||
|
IcingaWeb for RHEL and SUSE
|
||||||
|
===========================
|
||||||
|
|
||||||
|
Please check ./doc/installation.md
|
||||||
|
for requirements and database setup.
|
||||||
|
EOF
|
||||||
|
|
||||||
%install
|
%install
|
||||||
[ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot}
|
[ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot}
|
||||||
|
@ -212,6 +216,7 @@ Icinga 1.x
|
||||||
|
|
||||||
# prepare configuration for sub packages
|
# prepare configuration for sub packages
|
||||||
|
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
# Add apacheuser in the icingacmd group
|
# Add apacheuser in the icingacmd group
|
||||||
# If the group exists, add the apacheuser in the icingacmd group.
|
# If the group exists, add the apacheuser in the icingacmd group.
|
||||||
|
@ -238,12 +243,7 @@ fi
|
||||||
%files
|
%files
|
||||||
# main dirs
|
# main dirs
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%if "%{_vendor}" == "redhat"
|
%doc etc/schema doc README.RHEL.SUSE
|
||||||
%doc etc/schema doc
|
|
||||||
%endif
|
|
||||||
%if "%{_vendor}" == "suse"
|
|
||||||
%doc etc/schema doc
|
|
||||||
%endif
|
|
||||||
%{_datadir}/%{name}/application
|
%{_datadir}/%{name}/application
|
||||||
%{_datadir}/%{name}/library
|
%{_datadir}/%{name}/library
|
||||||
%{_datadir}/%{name}/public
|
%{_datadir}/%{name}/public
|
||||||
|
@ -256,10 +256,6 @@ fi
|
||||||
# logs
|
# logs
|
||||||
%attr(2775,%{apacheuser},%{apachegroup}) %dir %{logdir}
|
%attr(2775,%{apacheuser},%{apachegroup}) %dir %{logdir}
|
||||||
|
|
||||||
%files doc
|
|
||||||
%defattr(-,root,root)
|
|
||||||
%doc doc
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Sun Oct 20 2013 Michael Friedrich <michael.friedrich@netways.de> - 0.0.1
|
* Sun Oct 20 2013 Michael Friedrich <michael.friedrich@netways.de> - 0.0.1
|
||||||
- initial creation
|
- initial creation
|
||||||
|
|
Loading…
Reference in New Issue