Merge lp:~billy-olsen/charms/trusty/nova-compute/1468306 into lp:~openstack-charmers-archive/charms/trusty/nova-compute/next

Proposed by Billy Olsen
Status: Merged
Merged at revision: 197
Proposed branch: lp:~billy-olsen/charms/trusty/nova-compute/1468306
Merge into: lp:~openstack-charmers-archive/charms/trusty/nova-compute/next
Diff against target: 90 lines (+28/-0)
6 files modified
hooks/nova_compute_context.py (+13/-0)
templates/icehouse/nova.conf (+3/-0)
templates/juno/nova.conf (+3/-0)
templates/kilo/nova.conf (+2/-0)
templates/mitaka/nova.conf (+2/-0)
templates/parts/cinder (+5/-0)
To merge this branch: bzr merge lp:~billy-olsen/charms/trusty/nova-compute/1468306
Reviewer Review Type Date Requested Status
James Page Needs Fixing
Review via email: mp+286222@code.launchpad.net
To post a comment you must log in.
Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_lint_check #661 nova-compute-next for billy-olsen mp286222
    LINT OK: passed

Build: http://10.245.162.36:8080/job/charm_lint_check/661/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_unit_test #572 nova-compute-next for billy-olsen mp286222
    UNIT OK: passed

Build: http://10.245.162.36:8080/job/charm_unit_test/572/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_amulet_test #268 nova-compute-next for billy-olsen mp286222
    AMULET OK: passed

Build: http://10.245.162.36:8080/job/charm_amulet_test/268/

Revision history for this message
James Page (james-page) wrote :

Please can you rebase and add the same snippet to the mitaka template - thanks!

Other than that LGTM.

review: Needs Fixing
194. By Billy Olsen

Merge with next

195. By Billy Olsen

Add cinder's snippet to mitaka's nova.conf

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_lint_check #750 nova-compute-next for billy-olsen mp286222
    LINT OK: passed

Build: http://10.245.162.36:8080/job/charm_lint_check/750/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_unit_test #656 nova-compute-next for billy-olsen mp286222
    UNIT OK: passed

Build: http://10.245.162.36:8080/job/charm_unit_test/656/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_amulet_test #304 nova-compute-next for billy-olsen mp286222
    AMULET OK: passed

Build: http://10.245.162.36:8080/job/charm_amulet_test/304/

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'hooks/nova_compute_context.py'
2--- hooks/nova_compute_context.py 2015-11-10 13:39:24 +0000
3+++ hooks/nova_compute_context.py 2016-02-17 17:26:54 +0000
4@@ -248,6 +248,14 @@
5 rid=rid, unit=unit)
6 return volume_service
7
8+ @property
9+ def region(self):
10+ region = None
11+ for rid in relation_ids('cloud-compute'):
12+ for unit in related_units(rid):
13+ region = relation_get('region', rid=rid, unit=unit)
14+ return region
15+
16 def flat_dhcp_context(self):
17 ec2_host = None
18 for rid in relation_ids('cloud-compute'):
19@@ -400,6 +408,11 @@
20
21 if self.restart_trigger():
22 ctxt['restart_trigger'] = self.restart_trigger()
23+
24+ region = self.region
25+ if region:
26+ ctxt['region'] = region
27+
28 return ctxt
29
30
31
32=== modified file 'templates/icehouse/nova.conf'
33--- templates/icehouse/nova.conf 2015-09-25 14:58:23 +0000
34+++ templates/icehouse/nova.conf 2016-02-17 17:26:54 +0000
35@@ -113,6 +113,9 @@
36
37 {% if volume_service -%}
38 volume_api_class = nova.volume.cinder.API
39+{% if region -%}
40+os_region_name = {{ region }}
41+{% endif -%}
42 {% endif -%}
43
44 {% if user_config_flags -%}
45
46=== modified file 'templates/juno/nova.conf'
47--- templates/juno/nova.conf 2015-10-14 14:08:38 +0000
48+++ templates/juno/nova.conf 2016-02-17 17:26:54 +0000
49@@ -167,3 +167,6 @@
50 {% if disk_cachemodes -%}
51 disk_cachemodes = {{ disk_cachemodes }}
52 {% endif -%}
53+
54+{% include "parts/cinder" %}
55+
56
57=== modified file 'templates/kilo/nova.conf'
58--- templates/kilo/nova.conf 2016-02-09 13:52:08 +0000
59+++ templates/kilo/nova.conf 2016-02-17 17:26:54 +0000
60@@ -180,6 +180,8 @@
61
62 {% include "section-rabbitmq-oslo" %}
63
64+{% include "parts/cinder" %}
65+
66 [oslo_concurrency]
67 lock_path=/var/lock/nova
68
69
70=== modified file 'templates/mitaka/nova.conf'
71--- templates/mitaka/nova.conf 2016-02-12 12:03:15 +0000
72+++ templates/mitaka/nova.conf 2016-02-17 17:26:54 +0000
73@@ -181,5 +181,7 @@
74
75 {% include "section-rabbitmq-oslo" %}
76
77+{% include "parts/cinder" %}
78+
79 [oslo_concurrency]
80 lock_path=/var/lock/nova
81
82=== added file 'templates/parts/cinder'
83--- templates/parts/cinder 1970-01-01 00:00:00 +0000
84+++ templates/parts/cinder 2016-02-17 17:26:54 +0000
85@@ -0,0 +1,5 @@
86+{% if volume_service and volume_service == 'cinder' and region -%}
87+[cinder]
88+os_region_name = {{ region }}
89+{% endif -%}
90+

Subscribers

People subscribed via source and target branches