engine: resources: Small formatting cleanups
This commit is contained in:
@@ -38,9 +38,9 @@ import (
|
|||||||
"github.com/purpleidea/mgmt/util/errwrap"
|
"github.com/purpleidea/mgmt/util/errwrap"
|
||||||
"github.com/purpleidea/mgmt/util/socketset"
|
"github.com/purpleidea/mgmt/util/socketset"
|
||||||
|
|
||||||
// XXX: Do NOT use subscribe methods from this lib, as they are racey and
|
// XXX: Do NOT use subscribe methods from this lib, as they are racey
|
||||||
// do not clean up spawned goroutines. Should be replaced when a suitable
|
// and do not clean up spawned goroutines. Should be replaced when a
|
||||||
// alternative is available.
|
// suitable alternative is available.
|
||||||
"github.com/vishvananda/netlink"
|
"github.com/vishvananda/netlink"
|
||||||
"golang.org/x/sys/unix"
|
"golang.org/x/sys/unix"
|
||||||
)
|
)
|
||||||
@@ -50,18 +50,23 @@ func init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// IfacePrefix is the prefix used to identify unit files for managed links.
|
// IfacePrefix is the prefix used to identify unit files for managed
|
||||||
|
// links.
|
||||||
IfacePrefix = "mgmt-"
|
IfacePrefix = "mgmt-"
|
||||||
// networkdUnitFileDir is the location of networkd unit files which define
|
|
||||||
// the systemd network connections.
|
// networkdUnitFileDir is the location of networkd unit files which
|
||||||
|
// define the systemd network connections.
|
||||||
networkdUnitFileDir = "/etc/systemd/network/"
|
networkdUnitFileDir = "/etc/systemd/network/"
|
||||||
|
|
||||||
// networkdUnitFileExt is the file extension for networkd unit files.
|
// networkdUnitFileExt is the file extension for networkd unit files.
|
||||||
networkdUnitFileExt = ".network"
|
networkdUnitFileExt = ".network"
|
||||||
|
|
||||||
// networkdUnitFileUmask sets the permissions on the systemd unit file.
|
// networkdUnitFileUmask sets the permissions on the systemd unit file.
|
||||||
networkdUnitFileUmask = 0644
|
networkdUnitFileUmask = 0644
|
||||||
|
|
||||||
// ifaceUp is the up (on) interface state.
|
// ifaceUp is the up (on) interface state.
|
||||||
ifaceUp = "up"
|
ifaceUp = "up"
|
||||||
|
|
||||||
// ifaceDown is the down (off) interface state.
|
// ifaceDown is the down (off) interface state.
|
||||||
ifaceDown = "down"
|
ifaceDown = "down"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user