Re: [libvirt] [PATCH] Fixed service handling in specfile

2012-02-24 Thread Eric Blake
On 02/24/2012 04:28 AM, Martin Kletzander wrote:
> After adding the libvirt-guests service into usual runlevels, we used
> to start the libvirt-guests service. However this is usually not a
> good practice. As mentioned on fedoraproject wiki, the installations
> can be in changeroots, in an installer context, or in other situations
> where we don't want the services autostarted.
> ---
>  libvirt.spec.in |8 
>  1 files changed, 0 insertions(+), 8 deletions(-)
> 
> diff --git a/libvirt.spec.in b/libvirt.spec.in
> index 67cde23..072fd8e 100644
> --- a/libvirt.spec.in
> +++ b/libvirt.spec.in
> @@ -1027,14 +1027,6 @@ fi
>  %if %{with_systemd}
>  %else
>  /sbin/chkconfig --add libvirt-guests
> -if [ $1 -ge 1 ]; then
> -level=$(/sbin/runlevel | /bin/cut -d ' ' -f 2)
> -if /sbin/chkconfig --levels $level libvirt-guests; then
> -# this doesn't do anything but allowing for libvirt-guests to be
> -# stopped on the first shutdown
> -/sbin/service libvirt-guests start > /dev/null 2>&1 || true
> -fi
> -fi
>  %endif

ACK and pushed.

-- 
Eric Blake   ebl...@redhat.com+1-919-301-3266
Libvirt virtualization library http://libvirt.org



signature.asc
Description: OpenPGP digital signature
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] [PATCH] Fixed service handling in specfile

2012-02-24 Thread Martin Kletzander
After adding the libvirt-guests service into usual runlevels, we used
to start the libvirt-guests service. However this is usually not a
good practice. As mentioned on fedoraproject wiki, the installations
can be in changeroots, in an installer context, or in other situations
where we don't want the services autostarted.
---
 libvirt.spec.in |8 
 1 files changed, 0 insertions(+), 8 deletions(-)

diff --git a/libvirt.spec.in b/libvirt.spec.in
index 67cde23..072fd8e 100644
--- a/libvirt.spec.in
+++ b/libvirt.spec.in
@@ -1027,14 +1027,6 @@ fi
 %if %{with_systemd}
 %else
 /sbin/chkconfig --add libvirt-guests
-if [ $1 -ge 1 ]; then
-level=$(/sbin/runlevel | /bin/cut -d ' ' -f 2)
-if /sbin/chkconfig --levels $level libvirt-guests; then
-# this doesn't do anything but allowing for libvirt-guests to be
-# stopped on the first shutdown
-/sbin/service libvirt-guests start > /dev/null 2>&1 || true
-fi
-fi
 %endif

 %postun client -p /sbin/ldconfig
-- 
1.7.3.4

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list