Merge lp:~lamont/cloud-initramfs-tools/bug-1621615-device6 into lp:cloud-initramfs-tools

Proposed by LaMont Jones
Status: Merged
Merged at revision: 122
Proposed branch: lp:~lamont/cloud-initramfs-tools/bug-1621615-device6
Merge into: lp:cloud-initramfs-tools
Diff against target: 33 lines (+8/-4)
1 file modified
dyn-netconf/scripts/init-bottom/cloud-initramfs-dyn-netconf (+8/-4)
To merge this branch: bzr merge lp:~lamont/cloud-initramfs-tools/bug-1621615-device6
Reviewer Review Type Date Requested Status
cloud-initramfs-tools Pending
Review via email: mp+309719@code.launchpad.net

Commit message

Eliminating the regression in initramfs-tools added a DEVICE6 variable that cloud-initramfs-dyn-netconf needs to handle.

Description of the change

Eliminating the regression in initramfs-tools added a DEVICE6 variable that cloud-initramfs-dyn-netconf needs to handle.

To post a comment you must log in.
Revision history for this message
LaMont Jones (lamont) wrote :

Tested and confirmed to work (with 1621507). Needs to be added to zesty, and backported to yakkety/xenial.

Revision history for this message
Scott Moser (smoser) wrote :

One nit, other than that i think it looks good.

123. By LaMont Jones

No need for /tmp/net6-*.conf.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'dyn-netconf/scripts/init-bottom/cloud-initramfs-dyn-netconf'
2--- dyn-netconf/scripts/init-bottom/cloud-initramfs-dyn-netconf 2016-10-05 15:36:11 +0000
3+++ dyn-netconf/scripts/init-bottom/cloud-initramfs-dyn-netconf 2016-11-02 19:01:35 +0000
4@@ -102,7 +102,7 @@
5
6 ni_header > "$tmpf"
7 seen=","
8-for f in /run/net-*.conf /tmp/net-*.conf; do
9+for f in /run/net-*.conf /tmp/net-*.conf /run/net6-*.conf; do
10 [ -f "$f" ] || continue
11 dev=${f#*/net-}; dev=${dev%.conf};
12 # perhaps we saw this device from /run and now we're in /tmp
13@@ -112,13 +112,17 @@
14
15 DEVICE=""; PROTO=""; IPV4ADDR=""; IPV4NETMASK=""; IPV4GATEWAY="";
16 IPV4DNS0=""; IPV4DNS1=""; DNSDOMAIN=""; DOMAINSEARCH=""; filename="";
17- IPV4PROTO=""; IPV6PROTO=""; IPV6ADDR=""; IPV6NETMASK="";
18+ DEVICE6=""; IPV4PROTO=""; IPV6PROTO=""; IPV6ADDR=""; IPV6NETMASK="";
19 IPV6GATEWAY=""; IPV6DNS0=""; IPV6DNS1=""; IPV6DOMAINSEARCH="";
20 . "$f"
21
22 if [ -z "$DEVICE" ]; then
23- error "WARNING: $f had no 'DEVICE' set"
24- continue
25+ if [ -z "$DEVICE6" ]; then
26+ error "WARNING: $f had no 'DEVICE' or 'DEVICE6' set"
27+ continue
28+ else
29+ DEVICE="$DEVICE6"
30+ fi
31 fi
32 # If IPv6 is supported, we get both of these, and at least one of them
33 # is set. If we get both, use IPv4.

Subscribers

People subscribed via source and target branches