summaryrefslogtreecommitdiff
path: root/packages/redhat
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@yahoo-inc.com>2012-07-06 18:02:34 -0700
committerJoshua Harlow <harlowja@yahoo-inc.com>2012-07-06 18:02:34 -0700
commit8c484baa3d55d9deef97d6e191a9e420e4fde059 (patch)
tree2f1213f90d4518bf03c5fb741e78532e6055f3ef /packages/redhat
parentc7aeea86fb8a17e4402cfc42626dfff2fb04c1a0 (diff)
downloadvyos-cloud-init-8c484baa3d55d9deef97d6e191a9e420e4fde059.tar.gz
vyos-cloud-init-8c484baa3d55d9deef97d6e191a9e420e4fde059.zip
Got this working for 'brpm' again.
Diffstat (limited to 'packages/redhat')
-rw-r--r--packages/redhat/cloud-init.spec27
1 files changed, 6 insertions, 21 deletions
diff --git a/packages/redhat/cloud-init.spec b/packages/redhat/cloud-init.spec
index d0f83a4b..a9da7c5e 100644
--- a/packages/redhat/cloud-init.spec
+++ b/packages/redhat/cloud-init.spec
@@ -34,7 +34,7 @@ Requires: shadow-utils
Requires: {{r}}
{{endfor}}
-{{if init_d}}
+{{if sysvinit}}
Requires(post): chkconfig
Requires(postun): initscripts
Requires(preun): chkconfig
@@ -86,34 +86,22 @@ then
fi
{{endif}}
-{{if init_d_local}}
+{{if sysvinit}}
/sbin/chkconfig --add %{_initrddir}/cloud-init-local
-{{elif init_d}}
/sbin/chkconfig --add %{_initrddir}/cloud-init
-{{endif}}
-{{if init_d}}
/sbin/chkconfig --add %{_initrddir}/cloud-config
/sbin/chkconfig --add %{_initrddir}/cloud-final
{{endif}}
%preun
-{{if init_d_local}}
-if [ $1 -eq 0 ]
-then
- /sbin/service cloud-init-local stop >/dev/null 2>&1
- /sbin/chkconfig --del cloud-init-local
-fi
-{{elif init_d}}
+{{if sysvinit}}
if [ $1 -eq 0 ]
then
/sbin/service cloud-init stop >/dev/null 2>&1
/sbin/chkconfig --del cloud-init
-fi
-{{endif}}
-{{if init_d}}
-if [ $1 -eq 0 ]
-then
+ /sbin/service cloud-init-local stop >/dev/null 2>&1
+ /sbin/chkconfig --del cloud-init-local
/sbin/service cloud-config stop >/dev/null 2>&1
/sbin/chkconfig --del cloud-config
/sbin/service cloud-final stop >/dev/null 2>&1
@@ -139,13 +127,10 @@ fi
%files
-{{if init_d}}
+{{if sysvinit}}
%attr(0755, root, root) %{_initddir}/cloud-config
%attr(0755, root, root) %{_initddir}/cloud-final
-{{endif}}
-{{if init_d_local}}
%attr(0755, root, root) %{_initddir}/cloud-init-local
-{{elif init_d}}
%attr(0755, root, root) %{_initddir}/cloud-init
{{endif}}