Skip to content

Commit

Permalink
Merge pull request #1046 from RenaudWasTaken/state-const
Browse files Browse the repository at this point in the history
Add State status constants to spec-go
  • Loading branch information
tianon authored Jul 10, 2020
2 parents 8e2f17c + 66ad83f commit 3e4195d
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions specs-go/state.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
package specs

// ContainerState represents the state of a container.
type ContainerState string

const (
// StateCreating indicates that the container is being created
StateCreating ContainerState = "creating"

// StateCreated indicates that the runtime has finished the create operation
StateCreated ContainerState = "created"

// StateRunning indicates that the container process has executed the
// user-specified program but has not exited
StateRunning ContainerState = "running"

// StateStopped indicates that the container process has exited
StateStopped ContainerState = "stopped"
)

// State holds information about the runtime state of the container.
type State struct {
// Version is the version of the specification that is supported.
Expand Down

0 comments on commit 3e4195d

Please sign in to comment.