Merge lp:~stgraber/vmbuilder/lxd-metadata into lp:~ubuntu-on-ec2/vmbuilder/automated-ec2-builds

Proposed by Stéphane Graber
Status: Merged
Merged at revision: 720
Proposed branch: lp:~stgraber/vmbuilder/lxd-metadata
Merge into: lp:~ubuntu-on-ec2/vmbuilder/automated-ec2-builds
Diff against target: 46 lines (+13/-3)
1 file modified
lxd_metadata (+13/-3)
To merge this branch: bzr merge lp:~stgraber/vmbuilder/lxd-metadata
Reviewer Review Type Date Requested Status
Dan Watkins Pending
Review via email: mp+289009@code.launchpad.net

Description of the change

This updates the LXD metadata for all images.

It changes the cloud-init seed files to only be generated on create (at smoser's request) and adds a way for LXD to turn off the DHCP client (as needed for the new lxdbr0 bridge).

To post a comment you must log in.
Revision history for this message
Dan Watkins (oddbloke) wrote :

This is the same change as https://code.launchpad.net/~stgraber/cloudware/+git/cpc_build_tools/+merge/289010 so review is happening over there.

lp:~stgraber/vmbuilder/lxd-metadata updated
720. By Dan Watkins

lxd_metadata: Make eth0 DHCP configuration, and cloud-init seed generation time change

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lxd_metadata'
2--- lxd_metadata 2015-08-11 12:52:57 +0000
3+++ lxd_metadata 2016-03-15 05:31:57 +0000
4@@ -57,11 +57,11 @@
5 templates:
6 /var/lib/cloud/seed/nocloud-net/meta-data:
7 when:
8- - start
9+ - create
10 template: cloud-init-meta.tpl
11 /var/lib/cloud/seed/nocloud-net/user-data:
12 when:
13- - start
14+ - create
15 template: cloud-init-user.tpl
16 properties:
17 default: |
18@@ -69,12 +69,16 @@
19 {}
20 /var/lib/cloud/seed/nocloud-net/vendor-data:
21 when:
22- - start
23+ - create
24 template: cloud-init-vendor.tpl
25 properties:
26 default: |
27 #cloud-config
28 {}
29+ /etc/network/interfaces.d/eth0.cfg:
30+ when:
31+ - create
32+ template: interfaces.tpl
33 /etc/init/console.override:
34 when:
35 - create
36@@ -119,4 +123,10 @@
37 manual
38 EOF
39
40+cat > "${TMPL_D}/interfaces.tpl" << EOF
41+# The primary network interface
42+auto eth0
43+iface eth0 inet {% if config_get("user.network_mode", "") == "link-local" %}manual{% else %}dhcp{% endif %}
44+EOF
45+
46 tar --xz -cvf "${DEST}" -C ${TMP_D} metadata.yaml templates

Subscribers

People subscribed via source and target branches