Module: kamailio
Branch: master
Commit: 0efa0e315e7c70caf69bd7453adc22695c10c0f8
URL:
https://github.com/kamailio/kamailio/commit/0efa0e315e7c70caf69bd7453adc226…
Author: Sergey Safarov <s.safarov(a)gmail.com>
Committer: Sergey Safarov <s.safarov(a)gmail.com>
Date: 2017-02-13T09:21:40-05:00
pkg/kamailio/centos: Added tmpfiles initialization
---
Modified: pkg/kamailio/centos/7/kamailio.spec
---
Diff:
https://github.com/kamailio/kamailio/commit/0efa0e315e7c70caf69bd7453adc226…
Patch:
https://github.com/kamailio/kamailio/commit/0efa0e315e7c70caf69bd7453adc226…
---
diff --git a/pkg/kamailio/centos/7/kamailio.spec b/pkg/kamailio/centos/7/kamailio.spec
index 2ccc95e..4458ad1 100644
--- a/pkg/kamailio/centos/7/kamailio.spec
+++ b/pkg/kamailio/centos/7/kamailio.spec
@@ -593,6 +593,7 @@ make install-modules-all skip_modules="app_mono db_cassandra
db_oracle \
%if "%{?_unitdir}" == ""
# On RedHat 6 like
+install -d %{buildroot}%{_rundir}/kamailio
mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/rc.d/init.d
install -m755 pkg/kamailio/centos/%{?centos}/kamailio.init \
$RPM_BUILD_ROOT/%{_sysconfdir}/rc.d/init.d/kamailio
@@ -622,7 +623,12 @@ rm -rf "$RPM_BUILD_ROOT"
%post
+%if "%{?_unitdir}" == ""
/sbin/chkconfig --add kamailio
+%else
+%tmpfiles_create kamailio.conf
+/usr/bin/systemctl -q enable kamailio.service
+%endif