Merge lp:~zulcss/openstack-charm-testing/lxd-refactor into lp:openstack-charm-testing

Proposed by Chuck Short
Status: Merged
Merged at revision: 123
Proposed branch: lp:~zulcss/openstack-charm-testing/lxd-refactor
Merge into: lp:openstack-charm-testing
Diff against target: 1333 lines (+1062/-200)
13 files modified
bundles/dev/nc-lxd-3host.yaml (+0/-199)
bundles/lxd/lxd.yaml (+310/-0)
bundles/lxd/source/cinder-master.yaml (+10/-0)
bundles/lxd/source/glance-master.yaml (+10/-0)
bundles/lxd/source/horizon-master.yaml (+10/-0)
bundles/lxd/source/keystone-master.yaml (+10/-0)
bundles/lxd/source/lxd.yaml (+367/-0)
bundles/lxd/source/neutron-master.yaml (+19/-0)
bundles/lxd/source/nova-master.yaml (+19/-0)
configure (+1/-1)
profiles/lxd (+69/-0)
tools/images-lxd-convert.sh (+221/-0)
tools/images_lxd.sh (+16/-0)
To merge this branch: bzr merge lp:~zulcss/openstack-charm-testing/lxd-refactor
Reviewer Review Type Date Requested Status
Ryan Beisner Approve
Review via email: mp+265980@code.launchpad.net

Description of the change

LXD refactor.

To post a comment you must log in.
Revision history for this message
Ryan Beisner (1chb1n) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== removed file 'bundles/dev/nc-lxd-3host.yaml'
--- bundles/dev/nc-lxd-3host.yaml 2015-07-21 13:28:13 +0000
+++ bundles/dev/nc-lxd-3host.yaml 1970-01-01 00:00:00 +0000
@@ -1,199 +0,0 @@
1# An experimental bare metal bundle to test nc-lxd. Recommend vivid-kilo
2# for lxd testing. A three-machine smoosh. Temporarily uses kilo-support
3# branches.
4#
5# NOTES(beisner) Feb 23, 2015:
6# /!\ Beware, YMMV. This might be crazy, ill-advised for production use.
7# Ceph is excluded, as it would need 3 units for quorum.
8#
9# USAGE EXAMPLE:
10# Ensure default-series: vivid is defined in environments.yaml.
11# juju switch maas
12# juju bootstrap --series=vivid --upload-tools --constraints arch=amd64
13# juju-deployer -v -c <this_file>.yaml -d three-smoosh
14#=============================================================================
15three-smoosh:
16 series: vivid
17 services:
18 "juju-gui":
19 charm: "cs:trusty/juju-gui"
20 num_units: 1
21 annotations:
22 "gui-x": "500"
23 "gui-y": "1000"
24 to:
25 - "lxc:0"
26 keystone:
27 branch: lp:~openstack-charmers/charms/trusty/keystone/next
28 num_units: 1
29 options:
30 "admin-password": openstack
31 annotations:
32 "gui-x": "500"
33 "gui-y": "0"
34 to:
35 - "lxc:0"
36 neutron-gateway:
37 branch: lp:~openstack-charmers/charms/trusty/neutron-gateway/next
38 num_units: 1
39 options:
40 "ext-port": eth1
41 annotations:
42 "gui-x": "0"
43 "gui-y": "0"
44 to:
45 - "0"
46 neutron-api:
47 branch: lp:~openstack-charmers/charms/trusty/neutron-api/next
48 num_units: 1
49 options:
50 "neutron-security-groups": true
51 annotations:
52 "gui-x": "500"
53 "gui-y": "500"
54 to:
55 - "lxc:nova-compute=0"
56 neutron-openvswitch:
57 branch: lp:~openstack-charmers/charms/trusty/neutron-openvswitch/next
58 num_units: 0
59 annotations:
60 "gui-x": "250"
61 "gui-y": "500"
62 mysql:
63 branch: lp:~openstack-charmers/charms/trusty/percona-cluster/next
64 num_units: 1
65 options:
66 "max-connections": 20000
67 annotations:
68 "gui-x": "0"
69 "gui-y": "250"
70 to:
71 - "lxc:0"
72 nova-compute:
73 branch: lp:~zulcss/charms/trusty/nova-compute/nova-compute-lxd
74 num_units: 2
75 constraints: mem=8G
76 options:
77 openstack-origin: "ppa:zulcss/lxd-testing-vivid"
78 virt-type: lxd
79# lxd-block-device: /mnt/disk.img|100G
80 lxd-block-device: /dev/sdb /dev/vdb
81 enable-live-migration: True
82 enable-resize: True
83 "enable-live-migration": true
84 "enable-resize": true
85 "migration-auth-type": ssh
86 annotations:
87 "gui-x": "250"
88 "gui-y": "250"
89 glance:
90 branch: lp:~openstack-charmers/charms/trusty/glance/next
91 num_units: 1
92 annotations:
93 "gui-x": "250"
94 "gui-y": "0"
95 to:
96 - "lxc:nova-compute=1"
97 nova-cloud-controller:
98 branch: lp:~openstack-charmers/charms/trusty/nova-cloud-controller/next
99 num_units: 1
100 options:
101 "network-manager": Neutron
102 "quantum-security-groups": "yes"
103 annotations:
104 "gui-x": "0"
105 "gui-y": "500"
106 to:
107 - "lxc:nova-compute=0"
108 openstack-dashboard:
109 branch: lp:~openstack-charmers/charms/trusty/openstack-dashboard/next
110 num_units: 1
111 annotations:
112 "gui-x": "500"
113 "gui-y": "-250"
114 to:
115 - "lxc:0"
116 rabbitmq-server:
117 branch: lp:~openstack-charmers/charms/trusty/rabbitmq-server/next
118 num_units: 1
119 annotations:
120 "gui-x": "500"
121 "gui-y": "250"
122 to:
123 - "lxc:0"
124 cinder:
125 branch: lp:~openstack-charmers/charms/trusty/cinder/next
126 num_units: 1
127 options:
128 "block-device": /dev/sdb /dev/vdb
129 "glance-api-version": 2
130 annotations:
131 "gui-x": "750"
132 "gui-y": "0"
133 to:
134 - "lxc:0"
135 ntp:
136 charm: "cs:trusty/ntp-6"
137 num_units: 0
138 annotations:
139 "gui-x": "1000"
140 "gui-y": "0"
141 relations:
142 - - "nova-compute:amqp"
143 - "rabbitmq-server:amqp"
144 - - "neutron-gateway:amqp"
145 - "rabbitmq-server:amqp"
146 - - "keystone:shared-db"
147 - "mysql:shared-db"
148 - - "nova-cloud-controller:identity-service"
149 - "keystone:identity-service"
150 - - "glance:identity-service"
151 - "keystone:identity-service"
152 - - "neutron-api:identity-service"
153 - "keystone:identity-service"
154 - - "neutron-openvswitch:neutron-plugin-api"
155 - "neutron-api:neutron-plugin-api"
156 - - "neutron-api:shared-db"
157 - "mysql:shared-db"
158 - - "neutron-api:amqp"
159 - "rabbitmq-server:amqp"
160 - - "neutron-gateway:neutron-plugin-api"
161 - "neutron-api:neutron-plugin-api"
162 - - "glance:shared-db"
163 - "mysql:shared-db"
164 - - "glance:amqp"
165 - "rabbitmq-server:amqp"
166 - - "nova-cloud-controller:image-service"
167 - "glance:image-service"
168 - - "nova-compute:image-service"
169 - "glance:image-service"
170 - - "nova-cloud-controller:cloud-compute"
171 - "nova-compute:cloud-compute"
172 - - "nova-cloud-controller:amqp"
173 - "rabbitmq-server:amqp"
174 - - "nova-cloud-controller:quantum-network-service"
175 - "neutron-gateway:quantum-network-service"
176 - - "nova-compute:neutron-plugin"
177 - "neutron-openvswitch:neutron-plugin"
178 - - "neutron-openvswitch:amqp"
179 - "rabbitmq-server:amqp"
180 - - "openstack-dashboard:identity-service"
181 - "keystone:identity-service"
182 - - "nova-cloud-controller:shared-db"
183 - "mysql:shared-db"
184 - - "nova-cloud-controller:neutron-api"
185 - "neutron-api:neutron-api"
186 - - "cinder:image-service"
187 - "glance:image-service"
188 - - "cinder:amqp"
189 - "rabbitmq-server:amqp"
190 - - "cinder:identity-service"
191 - "keystone:identity-service"
192 - - "cinder:cinder-volume-service"
193 - "nova-cloud-controller:cinder-volume-service"
194 - - "cinder:shared-db"
195 - "mysql:shared-db"
196 - - "ntp:juju-info"
197 - "nova-compute:juju-info"
198 - - "ntp:juju-info"
199 - "neutron-gateway:juju-info"
2000
=== added directory 'bundles/lxd'
=== added file 'bundles/lxd/lxd.yaml'
--- bundles/lxd/lxd.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/lxd.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,310 @@
1# vim: set ts=2 et:
2# deployer bundle for development ('next') charms
3# UOSCI relies on this for OS-on-OS deployment testing
4openstack-services:
5 services:
6 mysql:
7 branch: lp:~openstack-charmers/charms/trusty/percona-cluster/next
8 constraints: mem=1G
9 options:
10 dataset-size: 50%
11 rabbitmq-server:
12 branch: lp:~openstack-charmers/charms/trusty/rabbitmq-server/next
13 constraints: mem=1G
14 ceph:
15 branch: lp:~openstack-charmers/charms/trusty/ceph/next
16 num_units: 3
17 constraints: mem=1G
18 options:
19 monitor-count: 3
20 fsid: 6547bd3e-1397-11e2-82e5-53567c8d32dc
21 monitor-secret: AQCXrnZQwI7KGBAAiPofmKEXKxu5bUzoYLVkbQ==
22 osd-devices: /dev/vdb
23 osd-reformat: "yes"
24 ephemeral-unmount: /mnt
25 keystone:
26 branch: lp:~openstack-charmers/charms/trusty/keystone/next
27 constraints: mem=1G
28 options:
29 admin-password: openstack
30 admin-token: ubuntutesting
31 openstack-dashboard:
32 branch: lp:~openstack-charmers/charms/trusty/openstack-dashboard/next
33 constraints: mem=1G
34 nova-compute:
35 branch: lp:~zulcss/charms/trusty/nova-compute/nova-compute-lxd
36 num_units: 3
37 constraints: mem=4G
38 options:
39 enable-live-migration: True
40 enable-resize: True
41 migration-auth-type: ssh
42 virt-type: lxd
43 nova-cloud-controller:
44 branch: lp:~openstack-charmers/charms/trusty/nova-cloud-controller/next
45 constraints: mem=1G
46 options:
47 network-manager: Neutron
48 quantum-security-groups: "yes"
49 neutron-gateway:
50 branch: lp:~openstack-charmers/charms/trusty/neutron-gateway/next
51 constraints: mem=1G
52 options:
53 instance-mtu: 1300
54 cinder:
55 branch: lp:~openstack-charmers/charms/trusty/cinder/next
56 options:
57 block-device: "None"
58 glance-api-version: 2
59 constraints: mem=1G
60 cinder-ceph:
61 branch: lp:~openstack-charmers/charms/trusty/cinder-ceph/next
62 glance:
63 branch: lp:~openstack-charmers/charms/trusty/glance/next
64 constraints: mem=1G
65 swift-proxy:
66 branch: lp:~openstack-charmers/charms/trusty/swift-proxy/next
67 constraints: mem=1G
68 options:
69 zone-assignment: manual
70 replicas: 3
71 swift-hash: fdfef9d4-8b06-11e2-8ac0-531c923c8fae
72 swift-storage-z1:
73 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
74 constraints: mem=1G
75 options:
76 zone: 1
77 block-device: vdb
78 overwrite: "true"
79 swift-storage-z2:
80 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
81 constraints: mem=1G
82 options:
83 zone: 2
84 block-device: vdb
85 overwrite: "true"
86 swift-storage-z3:
87 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
88 constraints: mem=1G
89 options:
90 zone: 3
91 block-device: vdb
92 overwrite: "true"
93 ceilometer:
94 branch: lp:~openstack-charmers/charms/trusty/ceilometer/next
95 constraints: mem=1G
96 ceilometer-agent:
97 branch: lp:~openstack-charmers/charms/trusty/ceilometer-agent/next
98 heat:
99 branch: lp:~openstack-charmers/charms/trusty/heat/next
100 mongodb:
101 branch: lp:charms/trusty/mongodb
102 constraints: mem=1G
103 lxd:
104 branch: lp:~zulcss/+junk/lxd-container
105 options:
106 lxd-block-device: /mnt/disk.img|20G
107 lxd-origin: ppa:ubuntu-lxc/lxd-git-master
108 lxd-use-source: True
109 lxd-trust-password: blah
110 relations:
111 - [ keystone, mysql ]
112 - [ nova-cloud-controller, mysql ]
113 - [ nova-cloud-controller, rabbitmq-server ]
114 - [ nova-cloud-controller, glance ]
115 - [ nova-cloud-controller, keystone ]
116 - [ nova-compute, nova-cloud-controller ]
117 - [ nova-compute, lxd ]
118 - [ nova-compute, mysql ]
119 - - nova-compute
120 - rabbitmq-server:amqp
121 - [ nova-compute, glance ]
122 - [ nova-compute, ceph ]
123 - [ glance, mysql ]
124 - [ glance, keystone ]
125 - [ glance, ceph ]
126 - [ glance, cinder ]
127 - [ cinder, mysql ]
128 - [ cinder, rabbitmq-server ]
129 - [ cinder, nova-cloud-controller ]
130 - [ cinder, keystone ]
131 - [ cinder, cinder-ceph ]
132 - [ cinder-ceph, ceph ]
133 - [ neutron-gateway, mysql ]
134 - [ neutron-gateway, nova-cloud-controller ]
135 - [ openstack-dashboard, keystone ]
136 - [ swift-proxy, keystone ]
137 - [ swift-proxy, swift-storage-z1 ]
138 - [ swift-proxy, swift-storage-z2 ]
139 - [ swift-proxy, swift-storage-z3 ]
140 - - ceilometer
141 - keystone:identity-service
142 - [ ceilometer, rabbitmq-server ]
143 - [ ceilometer, mongodb ]
144 - [ ceilometer-agent, nova-compute ]
145 - [ ceilometer-agent, ceilometer ]
146 - [ heat, mysql ]
147 - [ heat, keystone ]
148 - [ heat, rabbitmq-server ]
149openstack-singlerabbit:
150 inherits: openstack-services
151 relations:
152 - [ "neutron-gateway:amqp", rabbitmq-server ]
153openstack-icehouse:
154 inherits: openstack-singlerabbit
155 services:
156 neutron-api:
157 branch: lp:~openstack-charmers/charms/trusty/neutron-api/next
158 constraints: mem=1G
159 options:
160 neutron-security-groups: True
161 neutron-openvswitch:
162 branch: lp:~openstack-charmers/charms/trusty/neutron-openvswitch/next
163 relations:
164 - [ neutron-api, mysql ]
165 - [ neutron-api, rabbitmq-server ]
166 - [ neutron-api, nova-cloud-controller ]
167 - [ neutron-api, neutron-openvswitch ]
168 - [ neutron-api, keystone ]
169 - [ neutron-api, neutron-gateway ]
170 - [ neutron-openvswitch, nova-compute ]
171 - [ neutron-openvswitch, rabbitmq-server ]
172openstack-icehouse-msg-split:
173 inherits: openstack-services
174 services:
175 neutron-api:
176 branch: lp:~openstack-charmers/charms/trusty/neutron-api/next
177 constraints: mem=1G
178 options:
179 neutron-security-groups: True
180 neutron-openvswitch:
181 branch: lp:~openstack-charmers/charms/trusty/neutron-openvswitch/next
182 rabbitmq-server-neutron:
183 branch: lp:charms/trusty/rabbitmq-server
184 constraints: mem=1G
185 relations:
186 - [ neutron-api, mysql ]
187 - [ neutron-api, rabbitmq-server-neutron ]
188 - [ neutron-api, nova-cloud-controller ]
189 - [ neutron-api, neutron-openvswitch ]
190 - [ neutron-api, keystone ]
191 - [ neutron-api, neutron-gateway ]
192 - [ neutron-openvswitch, nova-compute ]
193 - [ neutron-openvswitch, rabbitmq-server-neutron ]
194 - [ "neutron-gateway:amqp-nova", rabbitmq-server ]
195 - [ "neutron-gateway:amqp", rabbitmq-server-neutron ]
196# icehouse
197precise-icehouse:
198 inherits: openstack-singlerabbit
199 series: precise
200 overrides:
201 openstack-origin: cloud:precise-icehouse
202 source: cloud:precise-icehouse
203precise-icehouse-proposed:
204 inherits: precise-icehouse
205 overrides:
206 openstack-origin: cloud:precise-icehouse/proposed
207 source: cloud:precise-updates/icehouse
208precise-icehouse-staging:
209 inherits: precise-icehouse
210 overrides:
211 openstack-origin: ppa:ubuntu-cloud-archive/icehouse-staging
212 source: ppa:ubuntu-cloud-archive/icehouse-staging
213precise-icehouse-trunk:
214 inherits: precise-icehouse
215 overrides:
216 openstack-origin: ppa:openstack-ubuntu-testing/icehouse
217 source: ppa:openstack-ubuntu-testing/icehouse
218trusty-icehouse:
219 inherits: openstack-icehouse
220 series: trusty
221trusty-icehouse-msg-split:
222 inherits: openstack-icehouse-msg-split
223 series: trusty
224trusty-icehouse-proposed:
225 inherits: trusty-icehouse
226 overrides:
227 source: proposed
228 openstack-origin: distro-proposed
229trusty-icehouse-trunk:
230 inherits: trusty-icehouse
231 overrides:
232 openstack-origin: ppa:openstack-ubuntu-testing/icehouse
233 source: ppa:openstack-ubuntu-testing/icehouse
234 offline-compression: "no"
235# juno
236trusty-juno:
237 inherits: openstack-icehouse
238 series: trusty
239 overrides:
240 openstack-origin: cloud:trusty-juno
241 source: cloud:trusty-juno
242trusty-juno-proposed:
243 inherits: trusty-juno
244 overrides:
245 openstack-origin: cloud:trusty-juno/proposed
246 source: cloud:trusty-juno/proposed
247trusty-juno-staging:
248 inherits: trusty-juno
249 overrides:
250 openstack-origin: ppa:ubuntu-cloud-archive/juno-staging
251 source: ppa:ubuntu-cloud-archive/juno-staging
252utopic-juno:
253 inherits: openstack-icehouse
254 series: utopic
255utopic-juno-proposed:
256 inherits: utopic-juno
257 overrides:
258 source: proposed
259 openstack-origin: distro-proposed
260# kilo
261trusty-kilo:
262 inherits: openstack-icehouse
263 series: trusty
264 overrides:
265 openstack-origin: cloud:trusty-kilo
266 source: cloud:trusty-kilo
267trusty-kilo-proposed:
268 inherits: trusty-kilo
269 overrides:
270 openstack-origin: cloud:trusty-kilo/proposed
271 source: cloud:trusty-kilo/proposed
272trusty-kilo-staging:
273 inherits: trusty-kilo
274 overrides:
275 openstack-origin: ppa:ubuntu-cloud-archive/kilo-staging
276 source: ppa:ubuntu-cloud-archive/kilo-staging
277vivid-kilo:
278 inherits: openstack-icehouse
279 series: vivid
280vivid-kilo-proposed:
281 inherits: vivid-kilo
282 overrides:
283 source: proposed
284 openstack-origin: distro-proposed
285# liberty
286trusty-liberty:
287 inherits: openstack-icehouse
288 series: trusty
289 overrides:
290 openstack-origin: cloud:trusty-liberty
291 source: cloud:trusty-liberty
292trusty-liberty-proposed:
293 inherits: trusty-liberty
294 overrides:
295 openstack-origin: cloud:trusty-liberty/proposed
296 source: cloud:trusty-liberty/proposed
297trusty-liberty-staging:
298 inherits: trusty-liberty
299 overrides:
300 openstack-origin: ppa:ubuntu-cloud-archive/liberty-staging
301 source: ppa:ubuntu-cloud-archive/liberty-staging
302wily-liberty:
303 inherits: openstack-icehouse
304 series: wily
305wily-liberty-proposed:
306 inherits: wily-liberty
307 overrides:
308 source: proposed
309 openstack-origin: distro-proposed
310
0311
=== added directory 'bundles/lxd/source'
=== added file 'bundles/lxd/source/cinder-master.yaml'
--- bundles/lxd/source/cinder-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/cinder-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,10 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: cinder,
6 repository: 'git://github.com/openstack/cinder',
7 branch: master}
8directory: /mnt/openstack-git
9http_proxy: http://squid.internal:3128
10https_proxy: http://squid.internal:3128
011
=== added file 'bundles/lxd/source/glance-master.yaml'
--- bundles/lxd/source/glance-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/glance-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,10 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: glance,
6 repository: 'git://github.com/openstack/glance',
7 branch: master}
8directory: /mnt/openstack-git
9http_proxy: http://squid.internal:3128
10https_proxy: http://squid.internal:3128
011
=== added file 'bundles/lxd/source/horizon-master.yaml'
--- bundles/lxd/source/horizon-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/horizon-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,10 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: horizon,
6 repository: 'git://github.com/openstack/horizon',
7 branch: master}
8directory: /mnt/openstack-git
9http_proxy: http://squid.internal:3128
10https_proxy: http://squid.internal:3128
011
=== added file 'bundles/lxd/source/keystone-master.yaml'
--- bundles/lxd/source/keystone-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/keystone-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,10 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: keystone,
6 repository: 'git://github.com/openstack/keystone',
7 branch: master}
8directory: /mnt/openstack-git
9http_proxy: http://squid.internal:3128
10https_proxy: http://squid.internal:3128
011
=== added file 'bundles/lxd/source/lxd.yaml'
--- bundles/lxd/source/lxd.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/lxd.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,367 @@
1# vim: set ts=2 et:
2# deployer bundle for development ('lxd') charms
3# UOSCI relies on this for OS-on-OS deployment testing
4openstack-services:
5 services:
6 mysql:
7 branch: lp:~openstack-charmers/charms/trusty/percona-cluster/next
8 constraints: mem=1G
9 options:
10 dataset-size: 50%
11 rabbitmq-server:
12 branch: lp:~openstack-charmers/charms/trusty/rabbitmq-server/next
13 constraints: mem=1G
14 ceph:
15 branch: lp:~openstack-charmers/charms/trusty/ceph/next
16 num_units: 3
17 constraints: mem=1G
18 options:
19 monitor-count: 3
20 fsid: 6547bd3e-1397-11e2-82e5-53567c8d32dc
21 monitor-secret: AQCXrnZQwI7KGBAAiPofmKEXKxu5bUzoYLVkbQ==
22 osd-devices: /dev/vdb
23 osd-reformat: "yes"
24 ephemeral-unmount: /mnt
25 keystone:
26 branch: lp:~openstack-charmers/charms/trusty/keystone/next
27 constraints: mem=1G
28 options:
29 admin-password: openstack
30 admin-token: ubuntutesting
31 openstack-dashboard:
32 branch: lp:~openstack-charmers/charms/trusty/openstack-dashboard/next
33 constraints: mem=1G
34 nova-compute:
35 branch: lp:~zulcss/charms/trusty/nova-compute/nova-compute-lxd
36 num_units: 3
37 constraints: mem=4G
38 options:
39 enable-live-migration: True
40 enable-resize: True
41 virt-type: lxd
42 nova-cloud-controller:
43 branch: lp:~openstack-charmers/charms/trusty/nova-cloud-controller/next
44 constraints: mem=1G
45 options:
46 network-manager: Neutron
47 quantum-security-groups: "yes"
48 neutron-gateway:
49 branch: lp:~openstack-charmers/charms/trusty/neutron-gateway/next
50 constraints: mem=1G
51 options:
52 instance-mtu: 1300
53 cinder:
54 branch: lp:~openstack-charmers/charms/trusty/cinder/next
55 options:
56 block-device: "None"
57 glance-api-version: 2
58 constraints: mem=1G
59# cinder-ceph:
60# branch: lp:~openstack-charmers/charms/trusty/cinder-ceph/next
61 glance:
62 branch: lp:~openstack-charmers/charms/trusty/glance/next
63 constraints: mem=1G
64 swift-proxy:
65 branch: lp:~openstack-charmers/charms/trusty/swift-proxy/next
66 constraints: mem=1G
67 options:
68 zone-assignment: manual
69 replicas: 3
70 swift-hash: fdfef9d4-8b06-11e2-8ac0-531c923c8fae
71 swift-storage-z1:
72 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
73 constraints: mem=1G
74 options:
75 zone: 1
76 block-device: vdb
77 overwrite: "true"
78 swift-storage-z2:
79 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
80 constraints: mem=1G
81 options:
82 zone: 2
83 block-device: vdb
84 overwrite: "true"
85 swift-storage-z3:
86 branch: lp:~openstack-charmers/charms/trusty/swift-storage/next
87 constraints: mem=1G
88 options:
89 zone: 3
90 block-device: vdb
91 overwrite: "true"
92 ceilometer:
93 branch: lp:~openstack-charmers/charms/trusty/ceilometer/next
94 constraints: mem=1G
95 ceilometer-agent:
96 branch: lp:~openstack-charmers/charms/trusty/ceilometer-agent/next
97 heat:
98 branch: lp:~openstack-charmers/charms/trusty/heat/next
99 mongodb:
100 branch: lp:charms/trusty/mongodb
101 constraints: mem=1G
102 lxd:
103 branch: lp:~zulcss/+junk/lxd-container
104 options:
105 lxd-block-device: /mnt/disk.img|20G
106 lxd-origin: ppa:ubuntu-lxc/lxd-git-master
107 lxd-use-source: True
108 lxd-trust-password: blah
109 relations:
110 - [ keystone, mysql ]
111 - [ nova-cloud-controller, mysql ]
112 - [ nova-cloud-controller, rabbitmq-server ]
113 - [ nova-cloud-controller, glance ]
114 - [ nova-cloud-controller, keystone ]
115 - [ nova-compute, nova-cloud-controller ]
116 - [ nova-compute, mysql ]
117 - [ nova-compute, lxd ]
118 - - nova-compute
119 - rabbitmq-server:amqp
120 - [ nova-compute, glance ]
121 - [ nova-compute, ceph ]
122 - [ glance, mysql ]
123 - [ glance, keystone ]
124 - [ glance, ceph ]
125 - [ glance, cinder ]
126 - [ cinder, mysql ]
127 - [ cinder, rabbitmq-server ]
128 - [ cinder, nova-cloud-controller ]
129 - [ cinder, keystone ]
130 - [ cinder, ceph ]
131# - [ cinder, cinder-ceph ]
132# - [ cinder-ceph, ceph ]
133 - [ neutron-gateway, mysql ]
134 - [ neutron-gateway, nova-cloud-controller ]
135 - [ openstack-dashboard, keystone ]
136 - [ swift-proxy, keystone ]
137 - [ swift-proxy, swift-storage-z1 ]
138 - [ swift-proxy, swift-storage-z2 ]
139 - [ swift-proxy, swift-storage-z3 ]
140 - - ceilometer
141 - keystone:identity-service
142 - [ ceilometer, rabbitmq-server ]
143 - [ ceilometer, mongodb ]
144 - [ ceilometer-agent, nova-compute ]
145 - [ ceilometer-agent, ceilometer ]
146 - [ heat, mysql ]
147 - [ heat, keystone ]
148 - [ heat, rabbitmq-server ]
149openstack-singlerabbit:
150 inherits: openstack-services
151 relations:
152 - [ "neutron-gateway:amqp", rabbitmq-server ]
153openstack-icehouse:
154 inherits: openstack-singlerabbit
155 services:
156 neutron-api:
157 branch: lp:~openstack-charmers/charms/trusty/neutron-api/next
158 constraints: mem=1G
159 options:
160 neutron-security-groups: True
161 neutron-openvswitch:
162 branch: lp:~openstack-charmers/charms/trusty/neutron-openvswitch/next
163 relations:
164 - [ neutron-api, mysql ]
165 - [ neutron-api, rabbitmq-server ]
166 - [ neutron-api, nova-cloud-controller ]
167 - [ neutron-api, neutron-openvswitch ]
168 - [ neutron-api, keystone ]
169 - [ neutron-api, neutron-gateway ]
170 - [ neutron-openvswitch, nova-compute ]
171 - [ neutron-openvswitch, rabbitmq-server ]
172openstack-icehouse-msg-split:
173 inherits: openstack-services
174 services:
175 neutron-api:
176 branch: lp:~openstack-charmers/charms/trusty/neutron-api/next
177 constraints: mem=1G
178 options:
179 neutron-security-groups: True
180 neutron-openvswitch:
181 branch: lp:~openstack-charmers/charms/trusty/neutron-openvswitch/next
182 rabbitmq-server-neutron:
183 branch: lp:charms/trusty/rabbitmq-server
184 constraints: mem=1G
185 relations:
186 - [ neutron-api, mysql ]
187 - [ neutron-api, rabbitmq-server-neutron ]
188 - [ neutron-api, nova-cloud-controller ]
189 - [ neutron-api, neutron-openvswitch ]
190 - [ neutron-api, keystone ]
191 - [ neutron-api, neutron-gateway ]
192 - [ neutron-openvswitch, nova-compute ]
193 - [ neutron-openvswitch, rabbitmq-server-neutron ]
194 - [ "neutron-gateway:amqp-nova", rabbitmq-server ]
195 - [ "neutron-gateway:amqp", rabbitmq-server-neutron ]
196# icehouse
197openstack-icehouse-git:
198 inherits: openstack-icehouse
199 services:
200 keystone:
201 options:
202 openstack-origin-git: include-file://keystone-icehouse.yaml
203 glance:
204 options:
205 openstack-origin-git: include-file://glance-icehouse.yaml
206 cinder:
207 options:
208 openstack-origin-git: include-file://cinder-icehouse.yaml
209 neutron-api:
210 options:
211 openstack-origin-git: include-file://neutron-icehouse.yaml
212 neutron-gateway:
213 options:
214 openstack-origin-git: include-file://neutron-icehouse.yaml
215 neutron-openvswitch:
216 options:
217 openstack-origin-git: include-file://neutron-icehouse.yaml
218 openstack-dashboard:
219 options:
220 openstack-origin-git: include-file://horizon-icehouse.yaml
221 nova-compute:
222 options:
223 openstack-origin-git: include-file://nova-icehouse.yaml
224 nova-cloud-controller:
225 options:
226 openstack-origin-git: include-file://nova-icehouse.yaml
227precise-icehouse:
228 inherits: openstack-icehouse-git
229 series: precise
230 overrides:
231 openstack-origin: cloud:precise-icehouse
232 source: cloud:precise-icehouse
233trusty-icehouse:
234 inherits: openstack-icehouse-git
235 series: trusty
236# juno
237openstack-juno-git:
238 inherits: openstack-icehouse
239 services:
240 keystone:
241 options:
242 openstack-origin-git: include-file://keystone-juno.yaml
243 glance:
244 options:
245 openstack-origin-git: include-file://glance-juno.yaml
246 cinder:
247 options:
248 openstack-origin-git: include-file://cinder-juno.yaml
249 neutron-api:
250 options:
251 openstack-origin-git: include-file://neutron-juno.yaml
252 neutron-gateway:
253 options:
254 openstack-origin-git: include-file://neutron-juno.yaml
255 neutron-openvswitch:
256 options:
257 openstack-origin-git: include-file://neutron-juno.yaml
258 openstack-dashboard:
259 options:
260 openstack-origin-git: include-file://horizon-juno.yaml
261 nova-compute:
262 options:
263 openstack-origin-git: include-file://nova-juno.yaml
264 nova-cloud-controller:
265 options:
266 openstack-origin-git: include-file://nova-juno.yaml
267trusty-juno:
268 inherits: openstack-juno-git
269 series: trusty
270 overrides:
271 openstack-origin: cloud:trusty-juno
272 source: cloud:trusty-juno
273utopic-juno:
274 inherits: openstack-juno-git
275 series: utopic
276# kilo
277openstack-kilo-git:
278 inherits: openstack-icehouse
279 services:
280 keystone:
281 options:
282 openstack-origin-git: include-file://keystone-kilo.yaml
283 glance:
284 options:
285 openstack-origin-git: include-file://glance-kilo.yaml
286 cinder:
287 options:
288 openstack-origin-git: include-file://cinder-kilo.yaml
289 neutron-api:
290 options:
291 openstack-origin-git: include-file://neutron-kilo.yaml
292 neutron-gateway:
293 options:
294 openstack-origin-git: include-file://neutron-kilo.yaml
295 neutron-openvswitch:
296 options:
297 openstack-origin-git: include-file://neutron-kilo.yaml
298 openstack-dashboard:
299 options:
300 openstack-origin-git: include-file://horizon-kilo.yaml
301 nova-compute:
302 options:
303 openstack-origin-git: include-file://nova-kilo.yaml
304 nova-cloud-controller:
305 options:
306 openstack-origin-git: include-file://nova-kilo.yaml
307trusty-kilo:
308 inherits: openstack-kilo-git
309 series: trusty
310 overrides:
311 openstack-origin: cloud:trusty-kilo
312 source: cloud:trusty-kilo
313trusty-kilo-proposed:
314 inherits: openstack-kilo-git
315 series: trusty
316 overrides:
317 openstack-origin: cloud:trusty-kilo/proposed
318 source: cloud:trusty-kilo/proposed
319vivid-kilo:
320 inherits: openstack-kilo-git
321 series: vivid
322# master
323openstack-master-git:
324 inherits: openstack-icehouse
325 services:
326 keystone:
327 options:
328 openstack-origin-git: include-file://keystone-master.yaml
329 glance:
330 options:
331 openstack-origin-git: include-file://glance-master.yaml
332 cinder:
333 options:
334 openstack-origin-git: include-file://cinder-master.yaml
335 neutron-api:
336 options:
337 openstack-origin-git: include-file://neutron-master.yaml
338 neutron-gateway:
339 options:
340 openstack-origin-git: include-file://neutron-master.yaml
341 neutron-openvswitch:
342 options:
343 openstack-origin-git: include-file://neutron-master.yaml
344 openstack-dashboard:
345 options:
346 openstack-origin-git: include-file://horizon-master.yaml
347 nova-compute:
348 options:
349 openstack-origin-git: include-file://nova-master.yaml
350 nova-cloud-controller:
351 options:
352 openstack-origin-git: include-file://nova-master.yaml
353trusty-master:
354 inherits: openstack-master-git
355 series: trusty
356 overrides:
357 openstack-origin: cloud:trusty-kilo
358 source: cloud:trusty-kilo
359trusty-master-proposed:
360 inherits: openstack-master-git
361 series: trusty
362 overrides:
363 openstack-origin: cloud:trusty-kilo/proposed
364 source: cloud:trusty-kilo/proposed
365vivid-master:
366 inherits: openstack-master-git
367 series: vivid
0368
=== added file 'bundles/lxd/source/neutron-master.yaml'
--- bundles/lxd/source/neutron-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/neutron-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,19 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: neutron-fwaas,
6 repository: 'git://github.com/openstack/neutron-fwaas',
7 branch: master}
8 - {name: neutron-lbaas,
9 repository: 'git://github.com/openstack/neutron-lbaas',
10 branch: master}
11 - {name: neutron-vpnaas,
12 repository: 'git://github.com/openstack/neutron-vpnaas',
13 branch: master}
14 - {name: neutron,
15 repository: 'git://github.com/openstack/neutron',
16 branch: master}
17directory: /mnt/openstack-git
18http_proxy: http://squid.internal:3128
19https_proxy: http://squid.internal:3128
020
=== added file 'bundles/lxd/source/nova-master.yaml'
--- bundles/lxd/source/nova-master.yaml 1970-01-01 00:00:00 +0000
+++ bundles/lxd/source/nova-master.yaml 2015-07-27 14:48:51 +0000
@@ -0,0 +1,19 @@
1repositories:
2 - {name: requirements,
3 repository: 'git://github.com/openstack/requirements',
4 branch: master}
5 - {name: neutron,
6 repository: 'git://github.com/openstack/neutron',
7 branch: master}
8 - {name: pylxd,
9 repository: 'https://github.com/lxc/pylxd',
10 branch: master}
11 - {name: nova-compute-lxd,
12 repository: 'https://github.com/lxc/nova-compute-lxd',
13 branch: master}
14 - {name: nova,
15 repository: 'git://github.com/openstack/nova',
16 branch: master}
17directory: /mnt/openstack-git
18http_proxy: http://squid.internal:3128
19https_proxy: http://squid.internal:3128
020
=== modified file 'configure'
--- configure 2015-07-15 09:26:36 +0000
+++ configure 2015-07-27 14:48:51 +0000
@@ -1,6 +1,6 @@
1#!/bin/sh1#!/bin/sh
22
3valid="stsstack dellstack kernelstack ppc64el powerkvm"3valid="stsstack dellstack kernelstack ppc64el powerkvm lxd"
44
5usage() {5usage() {
6 echo "$0 <profile>"6 echo "$0 <profile>"
77
=== added file 'profiles/lxd'
--- profiles/lxd 1970-01-01 00:00:00 +0000
+++ profiles/lxd 2015-07-27 14:48:51 +0000
@@ -0,0 +1,69 @@
1#!/bin/bash
2
3set -ex
4
5# Set serverstack defaults, if not already set.
6[[ -z "$GATEWAY" ]] && export GATEWAY="10.5.0.1"
7[[ -z "$CIDR_EXT" ]] && export CIDR_EXT="10.5.0.0/16"
8[[ -z "$FIP_RANGE" ]] && export FIP_RANGE="10.5.150.0:10.5.200.254"
9[[ -z "$NAMESERVER" ]] && export NAMESERVER="10.245.160.2"
10[[ -z "$CIDR_PRIV" ]] && export CIDR_PRIV="192.168.21.0/24"
11[[ -z "$SWIFT_IP" ]] && export SWIFT_IP="10.245.160.50"
12
13# Accept network type as first parameter, assume gre if unspecified
14net_type=${1:-"gre"}
15
16# If not on bare metal, add extra port to overcloud neutron-gateway and configure charm to use it
17if [[ "${BARE_METAL^^}" != "TRUE" ]]; then
18 source ~/novarc
19 ./bin/post-deploy-config neutron-gateway
20fi
21
22# Configure neutron networking on overcloud
23source novarc
24./bin/quantum-ext-net --network-type $net_type -g $GATEWAY -c $CIDR_EXT -f $FIP_RANGE ext_net
25./bin/quantum-tenant-net --network-type $net_type -t admin -r provider-router -N $NAMESERVER private $CIDR_PRIV
26
27# Create demo/testing users, tenants and flavor
28keystone tenant-create --name demo
29keystone user-create --name demo --tenant demo --pass pass --enabled true --email demo@dev.null
30keystone user-role-add --user demo --role Member --tenant demo || :
31keystone tenant-create --name alt_demo
32keystone user-create --name alt_demo --tenant alt_demo --pass secret --enabled true --email alt_demo@dev.null
33keystone user-role-add --user alt_demo --role Member --tenant alt_demo || :
34
35nova flavor-create m1.cirros 6 64 1 1
36nova flavor-create m1.tempest 7 256 5 1
37nova flavor-create m2.tempest 8 512 5 1
38
39# Gather vars for tempest template
40access=$(keystone --os-username demo --os-password pass --os-tenant-name demo ec2-credentials-create | grep access | awk '{ print $4 }')
41secret=$(keystone ec2-credentials-get --access $access | grep secret | awk '{ print $4 }')
42image_id=$(glance image-list | grep cirros | awk '{ print $2 }')
43image_alt_id=$(glance image-list | grep precise | awk '{ print $2 }')
44ext_net=$(neutron net-list | grep ext_net | awk '{ print $2 }')
45router=$(neutron router-list | grep provider-router | awk '{ print $2}')
46keystone=$(juju-deployer -f keystone)
47dashboard=$(juju-deployer -f openstack-dashboard)
48ncc=$(juju-deployer -f nova-cloud-controller)
49http=${OS_AUTH_PROTOCOL:-http}
50
51# Insert vars into tempest conf
52sed -e "s/__IMAGE_ID__/$image_id/g" -e "s/__IMAGE_ALT_ID__/$image_alt_id/g" \
53 -e "s/__DASHBOARD__/$dashboard/g" -e "s/__KEYSTONE__/$keystone/g" \
54 -e "s/__EXT_NET__/$ext_net/g" -e "s/__PROTO__/$http/g" \
55 -e "s/__SWIFT__/$SWIFT_IP/g" \
56 -e "s/__NCC__/$ncc/g" -e "s/__SECRET__/$secret/g" -e "s/__ACCESS__/$access/g" \
57 templates/tempest/tempest.conf.template > tempest.conf
58
59# Install dependencies and CLI tools
60# See also requirements.txt in tempest (probably need to sudo pip install -r requirements.txt)
61sudo apt-get install git testrepository subunit python-nose python-lxml python-boto \
62 python-junitxml python-subunit python-testresources python-oslotest python-stevedore \
63 python-cinderclient python-glanceclient python-heatclient python-keystoneclient \
64 python-neutronclient python-novaclient python-swiftclient python-ceilometerclient \
65 openvswitch-test openvswitch-common -y
66
67# Git tempest, place the rendered tempest template
68[ -d tempest ] || git clone https://github.com/openstack/tempest
69cp tempest.conf tempest/etc
070
=== added file 'tools/images-lxd-convert.sh'
--- tools/images-lxd-convert.sh 1970-01-01 00:00:00 +0000
+++ tools/images-lxd-convert.sh 2015-07-27 14:48:51 +0000
@@ -0,0 +1,221 @@
1#!/bin/bash
2
3VERBOSITY=0
4TEMP_D=""
5UC_PREP="/usr/share/lxc/hooks/ubuntu-cloud-prep"
6
7error() { echo "$@" 1>&2; }
8fail() { [ $# -eq 0 ] || error "$@"; exit 1; }
9
10Usage() {
11 cat <<EOF
12Usage: ${0##*/} [ options ] input-tar output-tarball
13
14 convert cloud-image-root.tar.gz into lxd compatible format,
15 and stuff nocloud seed in on the way.
16
17 options:
18 -h|--help this help
19 -v|--verbose
20 --metadata file to include as metadata.yaml
21 -u|--userdata U user-data for seed.
22 -S|--auth-key P pubkey to insert
23 -C|--cloud C do not seed instance
24 --zip Z compress with tar option Z (default 'J')
25EOF
26}
27
28bad_Usage() { Usage 1>&2; [ $# -eq 0 ] || error "$@"; return 1; }
29cleanup() {
30 [ -z "${TEMP_D}" -o ! -d "${TEMP_D}" ] || rm -Rf "${TEMP_D}"
31}
32
33debug() {
34 local level=${1}; shift;
35 [ "${level}" -gt "${VERBOSITY}" ] && return
36 error "${@}"
37}
38
39default_mdyaml() {
40cat <<EOF
41architecture: "$(uname -m)"
42creation_date: $(date "+%s")
43name: "$1"
44properties:
45 description: Ubuntu 14.04 LTS Intel 64bit
46 os: Ubuntu
47EOF
48}
49
50default_userdata() {
51 cat <<EOF
52#cloud-config
53manage_etc_hosts: localhost
54password: ubuntu
55chpasswd: { expire: false; }
56
57# pollinate hangs without socket timeout if it can't reach network
58random_seed:
59 command: null
60
61# growpart and resize_rootfs dont make sense, and should dtrt, but be sure.
62growpart:
63 mode: off
64resize_rootfs: null
65EOF
66}
67
68main() {
69 local short_opts="Chu:S:v"
70 local long_opts="auth-key:,cloud,help,metadata:,userdata:,verbose,zip:"
71 local getopt_out=""
72 local pt=""
73 getopt_out=$(getopt --name "${0##*/}" \
74 --options "${short_opts}" --long "${long_opts}" -- "$@") &&
75 eval set -- "${getopt_out}" ||
76 { bad_Usage; return; }
77
78 local cur="" next="" input="" output="" authkey="" z_opt="J" vflags=""
79 local ud=""
80 pt=( )
81
82 while [ $# -ne 0 ]; do
83 cur="$1"; next="$2";
84 case "$cur" in
85 -h|--help) Usage ; exit 0;;
86 -v|--verbose) VERBOSITY=$((${VERBOSITY}+1))
87 vflags="${vflags}v";;
88 --metadata) mdyaml="$next";;
89 -u|--userdata)
90 ud="$next"; pt[${#pt[@]}]="--userdata=$next"; shift;;
91 -S|--auth-key) pt[${#pt[@]}]="--auth-key=$next"; shift;;
92 -C|--cloud) pt[${#pt[@]}]="--cloud=$next"; shift;;
93 --zip) z_opt=$next; shift;;
94 --) shift; break;;
95 esac
96 shift;
97 done
98 [ -z "$vflags" ] || vflags="-$vflags"
99
100 [ $# -ne 0 ] || { bad_Usage "must provide arguments"; return; }
101 [ $# -eq 2 ] ||
102 { bad_Usage "confused by args. got $# expected 2 [$*]"; return; }
103
104 input=$1
105 output=$2
106
107 TEMP_D=$(mktemp -d "${TMPDIR:-/tmp}/${0##*/}.XXXXXX") ||
108 fail "failed to make tempdir"
109 trap cleanup EXIT
110
111 [ "$(id -u)" = "0" ] || { error "you're not root"; return 1; }
112 command -v "$UC_PREP" >/dev/null 2>&1 ||
113 { error "$UC_PREP not available"; return 1; }
114 [ "$input" = "-" -o -f "$input" ] ||
115 { error "$input: not a file or -"; return 1; }
116 [ -n "$output" ] || { error "$output: not a file or -"; return 1; }
117 [ -z "$mdyaml" -o -f "$mdyaml" ] ||
118 { error "$mdyaml: not a file"; return 1; }
119
120 if [ -z "$ud" ]; then
121 ud="$TEMP_D/user-data"
122 default_userdata > "$ud"
123 pt[${#pt[@]}]="--userdata=$ud"
124 fi
125
126 local extract create ucprep
127 mkdir -p "${TEMP_D}/rootfs" || { error "failed to make rootfs"; return 1; }
128 extract=(
129 tar -C "${TEMP_D}/rootfs"
130 --xattrs "--xattrs-include=*"
131 --anchored "--exclude=dev/*"
132 --numeric-owner -Sxpf "$input" )
133
134 create=(
135 tar -C "${TEMP_D}/"
136 --xattrs "--xattrs-include=*"
137 -cp${z_opt}f "$output" metadata.yaml rootfs )
138 create_pxz=(
139 bash -c 'set -o pipefail;
140 tar -C "$1" --xattrs "--xattrs-include=*" \
141 -cpf - metadata.yaml rootfs |
142 pxz -cv - > "$2"' -- "${TEMP_D}" "$output"
143 )
144 command -v pxz >/dev/null 2>&1 && create=( "${create_pxz[@]}" )
145
146 ucprep=(
147 "${UC_PREP}" $vflags "${pt[@]}" "${TEMP_D}/rootfs" )
148
149 if [ -n "$metadata" ]; then
150 cp "$metadata" "${TEMP_D}/metadata.yaml" ||
151 { error "failed cp '$metadata' metadata.yaml"; return 1; }
152 debug 1 "copied metadata.yaml from '$metadata'"
153 else
154 local tname=""
155 tname=${input%.gz};
156 tname=${tname%.tar};
157 [ "$input" = "-" ] && tname="unknown name"
158 default_mdyaml "$tname" > "${TEMP_D}/metadata.yaml" ||
159 { error "failed write metadata.yaml"; return 1; }
160 debug 1 "wrote questionable metadata.yaml file"
161 fi
162
163 debug 1 "extracting tar to tempdir"
164 debug 2 "cmd: ${extract[*]}"
165 "${extract[@]}" || { error "failed extraction"; return 1; }
166
167 debug 1 "hacking/fixing for lxd"
168 debug 2 "gettys just dont make sense, and upstart restarts"
169 ( cd "${TEMP_D}/rootfs" &&
170 for f in etc/init/tty*.conf; do
171 [ -f "$f" ] || continue
172 #[ "${f##*/}" = "tty1.conf" ] || continue
173 o=${f%.conf}.override
174 debug 3 "manual > $o"
175 echo "manual" > "$o"
176 done
177 )
178
179 debug 2 "update-motd runs from mounted-run.conf on mounted tmpfs"
180 # this is too late to fix via bootcmd
181 nox="
182 etc/update-motd.d/90-updates-available
183 etc/update-motd.d/91-release-upgrade
184 usr/lib/ubuntu-release-upgrader/release-upgrade-motd
185 usr/lib/update-notifier/apt-check
186 usr/lib/update-notifier/update-motd-updates-available
187 "
188 ( cd "${TEMP_D}/rootfs" &&
189 for f in $nox; do [ -e "$f" ] &&
190 debug 3 "chmod -x '$f'" && chmod -x "$f"; done )
191
192 debug 2 "pollinate is heavy, disabling"
193 ( cd "${TEMP_D}/rootfs"
194 f=etc/init/pollinate.conf
195 c=${f%.conf}.override
196 [ -f "$f" ] && debug 3 "manual > $c" && echo "manual" > "$c"
197 )
198
199 debug 2 "mot.d is annoying here (LP: #1426023)"
200 # this affects ssh in time. as mot.d is run on ssh login
201 ( cd "$TEMP_D/rootfs" &&
202 sudo sed -i '/^[^#].*pam_motd/s/^/#/' etc/pam.d/sshd )
203
204 debug 2 "disabling irqbalance (LP: #1454273)"
205 ( cd "$TEMP_D/rootfs" &&
206 f=etc/init/irqbalance.conf
207 c=${f%.conf}.override
208 [ -f "$f" ] && debug 3 "manual > $c" && echo "manual" > "$c" )
209
210 debug 1 "running ucprep: ${ucprep[*]}"
211 "${ucprep[@]}" ||
212 { error "failed to run ${ucprep[*]}"; return 1; }
213
214 debug 1 "writing tar to $out: ${create[*]}"
215 debug 2 "cmd: ${create[*]}"
216 "${create[@]}" || fail "failed writing tar to $out"
217 debug 1 "finished [${SECONDS}]"
218}
219
220main "$@"
221# vi: ts=4 noexpandtab
0222
=== added file 'tools/images_lxd.sh'
--- tools/images_lxd.sh 1970-01-01 00:00:00 +0000
+++ tools/images_lxd.sh 2015-07-27 14:48:51 +0000
@@ -0,0 +1,16 @@
1#!/bin/bash -e
2# Download LX images and add to glance
3
4# Download images if not already present
5mkdir -p ~/images
6[ -f ~/images/trusty-server-cloudimg-amd64-root.tar.gz ] || {
7 wget -O ~/images/trusty-server-cloudimg-amd64-root.tar.gz http://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-root.tar.gz
8}
9
10sudo images-lxd-convert.sh ~/images/trusty-server-cloudimg-amd64-root.tar.gz \
11 ~/images/trusty-server-cloudimg-amd64-lxd.tar.gz
12
13# Upload glance images to overcloud
14glance image-create --name="trusty-lxd-amd64" --is-public=true --progress \
15 --container-format=bare --disk-format=qcow2 < ~/images/trusty-server-cloudimg-amd64-lxd.tar.gz
16

Subscribers

People subscribed via source and target branches

to status/vote changes: