~ubuntu-branches/ubuntu/wily/juju-core/wily

« back to all changes in this revision

Viewing changes to src/launchpad.net/juju-core/cmd/juju/status.go

  • Committer: Package Import Robot
  • Author(s): James Page
  • Date: 2014-03-28 08:58:42 UTC
  • mfrom: (1.1.21)
  • Revision ID: package-import@ubuntu.com-20140328085842-cyzrgc120bdfxwj0
Tags: 1.17.7-0ubuntu1
* New upstream point release, including fixes for:
  - no debug log with all providers on Ubuntu 14.04 (LP: #1294776).
* d/control: Add cpu-checker dependency to juju-local (LP: #1297077).

Show diffs side-by-side

added added

removed removed

Lines of Context:
158
158
        Exposed       bool                  `json:"exposed" yaml:"exposed"`
159
159
        Life          string                `json:"life,omitempty" yaml:"life,omitempty"`
160
160
        Relations     map[string][]string   `json:"relations,omitempty" yaml:"relations,omitempty"`
 
161
        Networks      map[string][]string   `json:"networks,omitempty" yaml:"networks,omitempty"`
161
162
        SubordinateTo []string              `json:"subordinate-to,omitempty" yaml:"subordinate-to,omitempty"`
162
163
        Units         map[string]unitStatus `json:"units,omitempty" yaml:"units,omitempty"`
163
164
}
256
257
                Exposed:       service.Exposed,
257
258
                Life:          service.Life,
258
259
                Relations:     service.Relations,
 
260
                Networks:      make(map[string][]string),
259
261
                CanUpgradeTo:  service.CanUpgradeTo,
260
262
                SubordinateTo: service.SubordinateTo,
261
263
                Units:         make(map[string]unitStatus),
262
264
        }
 
265
        if len(service.Networks.Enabled) > 0 {
 
266
                out.Networks["enabled"] = service.Networks.Enabled
 
267
        }
 
268
        if len(service.Networks.Disabled) > 0 {
 
269
                out.Networks["disabled"] = service.Networks.Disabled
 
270
        }
263
271
        for k, m := range service.Units {
264
272
                out.Units[k] = formatUnit(m)
265
273
        }