2016-09-06 18:18:12 +00:00
|
|
|
package swarm
|
|
|
|
|
|
|
|
import (
|
|
|
|
"time"
|
|
|
|
|
2016-10-13 18:28:32 +00:00
|
|
|
"github.com/docker/docker/api/types/container"
|
2016-09-06 18:18:12 +00:00
|
|
|
"github.com/docker/docker/api/types/mount"
|
|
|
|
)
|
|
|
|
|
|
|
|
// ContainerSpec represents the spec of a container.
|
|
|
|
type ContainerSpec struct {
|
2016-10-13 18:28:32 +00:00
|
|
|
Image string `json:",omitempty"`
|
|
|
|
Labels map[string]string `json:",omitempty"`
|
|
|
|
Command []string `json:",omitempty"`
|
|
|
|
Args []string `json:",omitempty"`
|
2016-10-27 11:44:19 +00:00
|
|
|
Hostname string `json:",omitempty"`
|
2016-10-13 18:28:32 +00:00
|
|
|
Env []string `json:",omitempty"`
|
|
|
|
Dir string `json:",omitempty"`
|
|
|
|
User string `json:",omitempty"`
|
|
|
|
Groups []string `json:",omitempty"`
|
|
|
|
TTY bool `json:",omitempty"`
|
|
|
|
Mounts []mount.Mount `json:",omitempty"`
|
|
|
|
StopGracePeriod *time.Duration `json:",omitempty"`
|
|
|
|
Healthcheck *container.HealthConfig `json:",omitempty"`
|
2016-09-06 18:18:12 +00:00
|
|
|
}
|