Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Container ¶
type Container struct { ID string UUID string Version string Name string Description string ServiceName string StackName string State InstanceState HealthState HealthState Environment map[string]string Labels map[string]string Metadata map[string]interface{} PrimaryIpAddress string Ports []string ImageUUID string HostID string }
type Event ¶
type Event struct { ID string Timestamp time.Time Kind EventKind ContainerData Container HostData Host ServiceData Service StackData Stack }
Event is used to store information relating to a Rancher API "resource.change" event
func (Event) GetHealthState ¶
func (ev Event) GetHealthState() HealthState
func (Event) GetState ¶
func (ev Event) GetState() InstanceState
type HealthState ¶
type HealthState string
const ( // Common health states StateHealthy HealthState = "healthy" StateUnhealthy HealthState = "unhealthy" StateUpdatingHealthy HealthState = "updating-healthy" StateUpdatingUnhealthy HealthState = "updating-unhealthy" StateReconcile HealthState = "reconcile" StateInitializing HealthState = "initializing" StateReinitializing HealthState = "reinitializing" // Service specific health states StateDegraded HealthState = "degraded" StateStartedOnce HealthState = "started-once" // Unknown StateUnknown HealthState = "n/a" )
type InstanceState ¶
type InstanceState string
const ( // Service states ServiceInactive InstanceState = "inactive" ServiceActivating InstanceState = "activating" ServiceActive InstanceState = "active" ServiceUpdatingActive InstanceState = "updating-active" ServiceUpdatingInactive InstanceState = "updating-inactive" ServiceUpgraded // Container states ContainerStopping InstanceState = "stopping" ContainerStopped InstanceState = "stopped" ContainerStarting InstanceState = "starting" ContainerRunning InstanceState = "running" ContainerRestarting InstanceState = "restarting" // Host states HostInactive InstanceState = "inactive" HostActivating InstanceState = "activating" HostActive InstanceState = "active" )
type Stack ¶
type Stack struct { ID string UUID string Name string Description string State InstanceState HealthState HealthState }
Click to show internal directories.
Click to hide internal directories.