[Libguestfs] [PATCH v3 1/4] p2v: use yast2 lan on SUSE distros rather than NM

Richard W.M. Jones rjones at redhat.com
Wed Jun 22 12:26:49 UTC 2016


On Wed, Jun 22, 2016 at 02:02:27PM +0200, Cédric Bosdonnat wrote:
> NetworkManager isn't provided on SLES. As yast2 lan is available on all
> openSUSE / SLE distro, use it instead.
> ---
>  p2v/gui.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/p2v/gui.c b/p2v/gui.c
> index e720002..f8605a3 100644
> --- a/p2v/gui.c
> +++ b/p2v/gui.c
> @@ -654,7 +654,10 @@ test_connection_ok (gpointer user_data)
>  static void
>  configure_network_button_clicked (GtkWidget *w, gpointer data)
>  {
> -  ignore_value (system ("nm-connection-editor &"));
> +  if (access ("/sbin/yast2", X_OK) >= 0)
> +    ignore_value (system ("yast2 lan &"));
> +  else
> +    ignore_value (system ("nm-connection-editor &"));
>  }

Thanks, I have pushed this.

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