tags

package
v0.0.0-...-9ec3720 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2021 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// JujuTagPrefix is the prefix for Juju-managed tags.
	JujuTagPrefix = "juju-"

	// JujuModel is the tag name used for identifying the
	// Juju model a resource is part of.
	JujuModel = JujuTagPrefix + "model-uuid"

	// JujuController is the tag name used for identifying the
	// Juju controller that manages a resource.
	JujuController = JujuTagPrefix + "controller-uuid"

	// JujuIsController is the tag name used for determining
	// whether a machine instance is a controller or not.
	JujuIsController = JujuTagPrefix + "is-controller"

	// JujuUnitsDeployed is the tag name used for identifying
	// the units deployed to a machine instance. The value is
	// a space-separated list of the unit names.
	JujuUnitsDeployed = JujuTagPrefix + "units-deployed"

	// JujuStorageInstance is the tag name used for identifying
	// the Juju storage instance that an IaaS storage resource
	// is assigned to.
	JujuStorageInstance = JujuTagPrefix + "storage-instance"

	// JujuStorageOwner is the tag name used for identifying
	// the application or unit that owns the Juju storage instance
	// that an IaaS storage resource is assigned to.
	JujuStorageOwner = JujuTagPrefix + "storage-owner"

	// JujuMachine is the tag name used for identifying
	// the model and machine id corresponding to the
	// provisioned machine instance.
	JujuMachine = JujuTagPrefix + "machine-id"
)

Variables

This section is empty.

Functions

func ResourceTags

func ResourceTags(modelTag names.ModelTag, controllerTag names.ControllerTag, taggers ...ResourceTagger) map[string]string

ResourceTags returns tags to set on an infrastructure resource for the specified Juju environment.

Types

type ResourceTagger

type ResourceTagger interface {
	// ResourceTags returns a set of resource tags, and a
	// flag indicating whether or not any resource tags are
	// available.
	ResourceTags() (map[string]string, bool)
}

ResourceTagger is an interface that can provide resource tags.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL