[Libguestfs] [PATCH v2 2/2] firstboot: make SysV symlinks as relative on Debian

Richard W.M. Jones rjones at redhat.com
Thu Aug 4 13:06:39 UTC 2016


On Thu, Aug 04, 2016 at 01:56:10PM +0200, Pino Toscano wrote:
> Turn the rc.d symlinks for the guestfs-firstboot service as relative,
> instead of absolute paths: the result is the same (the service works the
> same), and this way is more coherent with symlinks created by
> update-rc.d.
> ---
>  customize/firstboot.ml | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/customize/firstboot.ml b/customize/firstboot.ml
> index 52dfbbe..706d63c 100644
> --- a/customize/firstboot.ml
> +++ b/customize/firstboot.ml
> @@ -197,11 +197,11 @@ WantedBy=default.target
>      g#mkdir_p "/etc/rc5.d";
>      g#ln_sf (sprintf "%s/firstboot.sh" firstboot_dir)
>        "/etc/init.d/guestfs-firstboot";
> -    g#ln_sf "/etc/init.d/guestfs-firstboot"
> +    g#ln_sf "../init.d/guestfs-firstboot"
>        "/etc/rc2.d/S99guestfs-firstboot";
> -    g#ln_sf "/etc/init.d/guestfs-firstboot"
> +    g#ln_sf "../init.d/guestfs-firstboot"
>        "/etc/rc3.d/S99guestfs-firstboot";
> -    g#ln_sf "/etc/init.d/guestfs-firstboot"
> +    g#ln_sf "../init.d/guestfs-firstboot"
>        "/etc/rc5.d/S99guestfs-firstboot";
>  
>      (* Try to remove the files of the old service. *)

ACK.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines.  Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v




More information about the Libguestfs mailing list