cannot specify --via in bundle?

Bug #1881823 reported by Paul Collins
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
High
Unassigned

Bug Description

I've just written a bundle for a production service based on my local development model.

Among other stuff, juju export-bundle against my development model gave me:

```
saas:
  postgresql:
    url: mm-rc3:admin/pgsql.postgresql
relations:
- - mattermost:db
  - postgresql:db
```

However, this relation was created with an additional --via flag, and will not function without it (postgresql needs to know which IPs to allow in pg_hba.conf).

Is there a way to specify this in a bundle?

Tags: bundles
Revision history for this message
Ian Booth (wallyworld) wrote :

It does seem like this is currently an omission.

Changed in juju:
milestone: none → 2.8.1
importance: Undecided → High
status: New → Triaged
Tim Penhey (thumper)
tags: added: bundles
Changed in juju:
milestone: 2.8.1 → 2.8-next
Ian Booth (wallyworld)
Changed in juju:
milestone: 2.8-next → 2.9.1
Ian Booth (wallyworld)
Changed in juju:
milestone: 2.9.1 → 2.9.2
Revision history for this message
Simon Richardson (simonrichardson) wrote :

The output from export-bundle should put this into an overlay, as it's unique to the deployment and not to underlying bundle itself.

The issue becomes where to put it within the bundle. We unfortunately can't add it to the existing relations list, as that expects relations to be a list of list of strings ([][]string)[1], but we could create a new field that exposes what we would like, that allows us to look up the related via, although we're duplicating the exact same information to expose the key.

Potentially:

    networks:
     - endpoints:
       - mattermost:db
       - postgresql:db
       via:
       - 10.0.0.0/24
       - 192.168.0.0/16
     - endpoints:
       - mattermost:admin
       - postgresql:admin
       via:
       - 10.0.0.0/12

Alternatively we push this to 3.0 and make a breaking change in bundle syntax to support via correctly:

    relations:
     - endpoints:
       - mattermost:db
       - postgresql:db
       via:
       - 10.0.0.0/24
       - 192.168.0.0/16

1. https://github.com/juju/charm/blob/master/bundledata.go#L61

Changed in juju:
milestone: 2.9.2 → 2.9.3
John A Meinel (jameinel)
Changed in juju:
milestone: 2.9.3 → 3.0.0
Changed in juju:
milestone: 3.0.0 → 3.0.1
Changed in juju:
milestone: 3.0.1 → 3.0.2
Changed in juju:
milestone: 3.0.2 → 3.0.3
Changed in juju:
assignee: nobody → Simon Richardson (simonrichardson)
Changed in juju:
assignee: Simon Richardson (simonrichardson) → nobody
milestone: 3.0.3 → 3.2.0
Changed in juju:
milestone: 3.2.0 → none
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.