cluster: introduce Machine.Inactive flag #38
Merged
amery
merged 3 commits from pr-amery-dns-ignore
into main
1 year ago
Loading…
Reference in new issue
There is no content yet.
Delete Branch 'pr-amery-dns-ignore'
Deleting a branch is permanent. It CANNOT be undone. Continue?
reflected on disk as
none
on a file namedregion
these machines won't be included in the regional or zonal aliases
see comments
ID int
Name string `json:"-" yaml:"-"`
Inactive bool `json:"inactive,omitempty" yaml:"inactive,omitempty"`
Please name the field
Active
Active
breaks zero-value rules, everything would become inactive by defaultfunc (m *Machine) Active() bool {
return !m.Inactive
}
for _, r := range data {
switch r {
case "none":
m.Inactive = true
please see above s/Inactive/Active/ and switch logic.
z.ForEachMachine(func(p *Machine) bool {
term = fn(p)
if p.Active() {
@karasz it's currently called Inactive to deal with the zero value. Active by default, otherwise indicated.
Machine.Active()
renamed toMachine.IsActive()
LGTM
a910bba406
into main 1 year agoReviewers
a910bba406
.