Comment 2 for bug 1818032

Revision history for this message
Ryan Harper (raharper) wrote :

I verified the error with the supplied config in this bug.

% cat network_configs/fedora29-netplan-dhcp.yaml
network:
  version: 2
  ethernets:
    ens3:
      match:
        macaddress: 52:54:00:ab:cd:ef
      dhcp4: false
      dhcp6: false
      addresses:
        - 192.168.42.100/24
        - 2001:db8::100/32
      gateway4: 192.168.42.1
      gateway6: 2001:db8::1
      nameservers:
        search: [example.com]
        addresses: [192.168.42.53, 1.1.1.1]
(neipa) cloud-init % PYTHONPATH=`pwd` python3 cloudinit/cmd/main.py devel net-convert --debug --network-data network_configs/fedora29-netplan-dhcp.yaml --kind yaml -O sysconfig --distro fedora -d fedora_test

After apply your suggested patch, this resolve the issue.

% diff -u fedora_test/etc/sysconfig/network-scripts/ifcfg-ens3 fedora_test_fix/etc/sysconfig/network-scripts/ifcfg-ens3
--- fedora_test/etc/sysconfig/network-scripts/ifcfg-ens3 2019-02-28 11:42:06.313736619 -0600
+++ fedora_test_fix/etc/sysconfig/network-scripts/ifcfg-ens3 2019-02-28 11:46:42.839672661 -0600
@@ -1,9 +1,8 @@
 # Created by cloud-init on instance boot automatically, do not edit.
 #
-BOOTPROTO=dhcp
+BOOTPROTO=none
 DEFROUTE=yes
 DEVICE=ens3
-DHCPV6C=yes
 DNS1=192.168.42.53
 DNS2=1.1.1.1
 DOMAIN=example.com