Merge lp:~bbaqar/charms/trusty/plumgrid-gateway/ext-interface-static into lp:~junaidali/charms/trusty/plumgrid-gateway/trunk

Proposed by Junaid Ali
Status: Merged
Merged at revision: 32
Proposed branch: lp:~bbaqar/charms/trusty/plumgrid-gateway/ext-interface-static
Merge into: lp:~junaidali/charms/trusty/plumgrid-gateway/trunk
Diff against target: 47 lines (+10/-16) (has conflicts)
2 files modified
hooks/pg_gw_utils.py (+6/-16)
templates/kilo/ifcs.conf (+4/-0)
Text conflict in templates/kilo/ifcs.conf
To merge this branch: bzr merge lp:~bbaqar/charms/trusty/plumgrid-gateway/ext-interface-static
Reviewer Review Type Date Requested Status
Junaid Ali Pending
Review via email: mp+296969@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'hooks/pg_gw_utils.py'
2--- hooks/pg_gw_utils.py 2016-05-23 10:31:14 +0000
3+++ hooks/pg_gw_utils.py 2016-06-09 17:28:49 +0000
4@@ -285,22 +285,12 @@
5 Gateway node can have multiple interfaces. This function parses json
6 provided in config to get all gateway interfaces for this node.
7 '''
8- node_interfaces = []
9- try:
10- all_interfaces = json.loads(config('external-interfaces'))
11- except ValueError:
12- raise ValueError("Invalid json provided for gateway interfaces")
13- hostname = get_unit_hostname()
14- if hostname in all_interfaces:
15- node_interfaces = all_interfaces[hostname].split(',')
16- elif 'DEFAULT' in all_interfaces:
17- node_interfaces = all_interfaces['DEFAULT'].split(',')
18- for interface in node_interfaces:
19- if not interface_exists(interface):
20- log('Provided gateway interface %s does not exist'
21- % interface)
22- raise ValueError('Provided gateway interface does not exist')
23- return node_interfaces
24+ interface = config('external-interfaces')
25+ if not interface_exists(interface):
26+ log('Provided gateway interface %s does not exist'
27+ % interface)
28+ raise ValueError('Provided gateway interface does not exist')
29+ return interface
30
31
32 def ensure_mtu():
33
34=== modified file 'templates/kilo/ifcs.conf'
35--- templates/kilo/ifcs.conf 2016-05-21 11:54:18 +0000
36+++ templates/kilo/ifcs.conf 2016-06-09 17:28:49 +0000
37@@ -1,7 +1,11 @@
38 {{ fabric_interface }} = fabric_core host
39+<<<<<<< TREE
40 {% if ext_interfaces -%}
41 {% for dev in ext_interfaces -%}
42 {{ dev }} = access_phys
43 {% endfor -%}
44 {% endif -%}
45+=======
46+{{ ext_interfaces }} = access_phys
47+>>>>>>> MERGE-SOURCE
48

Subscribers

People subscribed via source and target branches

to all changes: