Browse Source

zones: change toml tags to match yaml and json output

Signed-off-by: Alejandro Mery <amery@jpi.io>
pull/1/head
Alejandro Mery 1 year ago
parent
commit
20484a5061
  1. 4
      pkg/zones/machine.go
  2. 4
      pkg/zones/zones.go

4
pkg/zones/machine.go

@ -10,8 +10,8 @@ import (
// A Machine is a machine on a Zone
type Machine struct {
zone *Zone
ID int
Name string `toml:"name" json:"-" yaml:"-"`
ID int `toml:"id"`
Name string `toml:"-" json:"-" yaml:"-"`
PublicAddresses []netip.Addr `toml:"public,omitempty" json:"public,omitempty" yaml:"public,omitempty"`
Rings []*RingInfo `toml:"rings,omitempty" json:"rings,omitempty" yaml:"rings,omitempty"`

4
pkg/zones/zones.go

@ -14,8 +14,8 @@ import (
type Zone struct {
zones *Zones
ID int
Name string
ID int `toml:"id"`
Name string `toml:"name"`
Machines []*Machine `toml:"machines"`
}

Loading…
Cancel
Save