Skip to content

Commit

Permalink
Separate relations into separate yaml document
Browse files Browse the repository at this point in the history
To adjust to new juju 3.2 behaviour that does not allow relations
referencing overlay applications in the base bundle.

Ref: https://bugs.launchpad.net/juju/+bug/2041785

Resolves: #149
Co-authored-by: Nicolas Bock <[email protected]>
  • Loading branch information
rafalop and nicolasbock committed Nov 28, 2023
1 parent 5e3e0ed commit 3ec5687
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions openstack/openstack.yaml.template
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ applications:
ssl_ca: *ssl_ca
ssl_cert: *ssl_cert
ssl_key: *ssl_key
---
relations:
- [ nova-cloud-controller:shared-db, __MYSQL_INTERFACE__ ]
- [ nova-cloud-controller:amqp, rabbitmq-server ]
Expand Down
8 changes: 4 additions & 4 deletions tools/juju-bundle-applications.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

for filename in sys.argv[1:]:
with open(filename, 'r') as f:
data = yaml.load(f, Loader=yaml.SafeLoader)
if 'applications' in data:
application_list.update(data['applications'].keys())

data = yaml.load_all(f, Loader=yaml.SafeLoader)
for d in data:
if 'applications' in d:
application_list.update(d['applications'].keys())
print('\n'.join(application_list))

0 comments on commit 3ec5687

Please sign in to comment.