Add labels for containers

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby 2016-02-11 13:44:25 -08:00
parent 76d69b4ed8
commit d6bd304c92
8 changed files with 134 additions and 109 deletions

View file

@ -37,6 +37,7 @@ func (s *apiServer) CreateContainer(ctx context.Context, c *types.CreateContaine
e.Stdin = c.Stdin e.Stdin = c.Stdin
e.Stdout = c.Stdout e.Stdout = c.Stdout
e.Stderr = c.Stderr e.Stderr = c.Stderr
e.Labels = c.Labels
e.StartResponse = make(chan supervisor.StartResponse, 1) e.StartResponse = make(chan supervisor.StartResponse, 1)
if c.Checkpoint != "" { if c.Checkpoint != "" {
e.Checkpoint = &runtime.Checkpoint{ e.Checkpoint = &runtime.Checkpoint{
@ -224,6 +225,7 @@ func createAPIContainer(c runtime.Container) (*types.Container, error) {
Id: c.ID(), Id: c.ID(),
BundlePath: c.Path(), BundlePath: c.Path(),
Processes: procs, Processes: procs,
Labels: c.Labels(),
Status: string(c.State()), Status: string(c.State()),
}, nil }, nil
} }

View file

@ -92,6 +92,7 @@ type CreateContainerRequest struct {
Stdin string `protobuf:"bytes,4,opt,name=stdin" json:"stdin,omitempty"` Stdin string `protobuf:"bytes,4,opt,name=stdin" json:"stdin,omitempty"`
Stdout string `protobuf:"bytes,5,opt,name=stdout" json:"stdout,omitempty"` Stdout string `protobuf:"bytes,5,opt,name=stdout" json:"stdout,omitempty"`
Stderr string `protobuf:"bytes,6,opt,name=stderr" json:"stderr,omitempty"` Stderr string `protobuf:"bytes,6,opt,name=stderr" json:"stderr,omitempty"`
Labels []string `protobuf:"bytes,7,rep,name=labels" json:"labels,omitempty"`
} }
func (m *CreateContainerRequest) Reset() { *m = CreateContainerRequest{} } func (m *CreateContainerRequest) Reset() { *m = CreateContainerRequest{} }
@ -308,6 +309,7 @@ type Container struct {
BundlePath string `protobuf:"bytes,3,opt,name=bundlePath" json:"bundlePath,omitempty"` BundlePath string `protobuf:"bytes,3,opt,name=bundlePath" json:"bundlePath,omitempty"`
Processes []*Process `protobuf:"bytes,4,rep,name=processes" json:"processes,omitempty"` Processes []*Process `protobuf:"bytes,4,rep,name=processes" json:"processes,omitempty"`
Status string `protobuf:"bytes,5,opt,name=status" json:"status,omitempty"` Status string `protobuf:"bytes,5,opt,name=status" json:"status,omitempty"`
Labels []string `protobuf:"bytes,6,rep,name=labels" json:"labels,omitempty"`
} }
func (m *Container) Reset() { *m = Container{} } func (m *Container) Reset() { *m = Container{} }
@ -1148,101 +1150,102 @@ var _API_serviceDesc = grpc.ServiceDesc{
} }
var fileDescriptor0 = []byte{ var fileDescriptor0 = []byte{
// 1524 bytes of a gzipped FileDescriptorProto // 1537 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x58, 0xdb, 0x6e, 0x1b, 0xc5, 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x58, 0xd9, 0x6e, 0xdc, 0x54,
0x1b, 0x8f, 0xed, 0xb5, 0x63, 0x7f, 0x3e, 0x24, 0xd9, 0x9c, 0x1c, 0xf7, 0xdf, 0x7f, 0xcb, 0xb6, 0x18, 0xce, 0x8c, 0x3d, 0xdb, 0x3f, 0x4b, 0x12, 0x67, 0x9b, 0x4c, 0x29, 0x0d, 0x6e, 0xa1, 0x15,
0xd0, 0x0a, 0x55, 0x51, 0x49, 0x39, 0x94, 0x22, 0x01, 0x25, 0xad, 0x5a, 0x50, 0x0b, 0x51, 0x93, 0xaa, 0xa2, 0x92, 0xb2, 0x94, 0x22, 0x01, 0x25, 0xad, 0x5a, 0x50, 0x0b, 0x51, 0x93, 0x20, 0x71,
0x20, 0x71, 0x83, 0xb5, 0xd9, 0x1d, 0xec, 0x21, 0x7b, 0x62, 0x77, 0x36, 0x89, 0xc5, 0x1b, 0x70, 0xc3, 0xc8, 0x63, 0x1f, 0x66, 0x0e, 0xf1, 0x86, 0x7d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0x93, 0x99, 0x5d, 0xf0, 0x50, 0xca, 0xcc, 0x2e, 0x7c, 0x13, 0xad, 0x18, 0xdf, 0x40, 0xaf, 0xf8,
0xef, 0xcb, 0x46, 0xc0, 0x9b, 0x4b, 0x96, 0xb3, 0xdc, 0x13, 0x65, 0xb0, 0x55, 0xdc, 0xd4, 0x5a, 0x2a, 0x31, 0x52, 0x92, 0xe6, 0x3e, 0x96, 0x06, 0xd7, 0x17, 0x9c, 0x66, 0x06, 0xdf, 0x97, 0x8d,
0xf7, 0xa1, 0x21, 0xef, 0xa3, 0xba, 0x00, 0x0a, 0xd7, 0xd3, 0x41, 0x27, 0xbf, 0x6b, 0xad, 0xdc, 0x80, 0x37, 0x97, 0x34, 0x67, 0xb9, 0x27, 0xcb, 0x60, 0xb3, 0xb8, 0x99, 0x69, 0xdd, 0x83, 0xba,
0xaf, 0xe0, 0xcc, 0x6b, 0x3e, 0x23, 0x4c, 0x76, 0x47, 0xde, 0xd5, 0x8c, 0x8a, 0xd8, 0xe4, 0x2a, 0xbc, 0x8f, 0x66, 0x05, 0x50, 0xb8, 0x9e, 0x0e, 0x3a, 0xf9, 0x5d, 0x73, 0xe5, 0x5e, 0x05, 0x67,
0x67, 0x0d, 0xf1, 0x1f, 0xca, 0x83, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0x06, 0x77, 0x88, 0xa2, 0x5e, 0xf3, 0x29, 0x61, 0xb2, 0x3b, 0xf2, 0xae, 0x66, 0x54, 0xc4, 0x26, 0x57, 0x19, 0xd5, 0xc5,
0x50, 0x11, 0x00, 0x00, 0x9f, 0x2c, 0xf7, 0xff, 0x0d, 0x00, 0x00, 0xff, 0xff, 0xa5, 0xa9, 0x7b, 0x24, 0x71, 0x11, 0x00,
0x00,
} }

View file

@ -34,6 +34,7 @@ message CreateContainerRequest {
string stdin = 4; // path to the file where stdin will be read (optional) string stdin = 4; // path to the file where stdin will be read (optional)
string stdout = 5; // path to file where stdout will be written (optional) string stdout = 5; // path to file where stdout will be written (optional)
string stderr = 6; // path to file where stderr will be written (optional) string stderr = 6; // path to file where stderr will be written (optional)
repeated string labels = 7;
} }
message CreateContainerResponse { message CreateContainerResponse {
@ -130,6 +131,7 @@ message Container {
string bundlePath = 3; // Path to OCI bundle string bundlePath = 3; // Path to OCI bundle
repeated Process processes = 4; // List of processes which run in container repeated Process processes = 4; // List of processes which run in container
string status = 5; // Container status ("running", "paused", etc.) string status = 5; // Container status ("running", "paused", etc.)
repeated string labels = 6;
} }
// Machine is information about machine on which containerd is run // Machine is information about machine on which containerd is run

View file

@ -114,6 +114,11 @@ var startCommand = cli.Command{
Name: "attach,a", Name: "attach,a",
Usage: "connect to the stdio of the container", Usage: "connect to the stdio of the container",
}, },
cli.StringSliceFlag{
Name: "label,l",
Value: &cli.StringSlice{},
Usage: "set labels for the container",
},
}, },
Action: func(context *cli.Context) { Action: func(context *cli.Context) {
var ( var (
@ -144,6 +149,7 @@ var startCommand = cli.Command{
Stdin: s.stdin, Stdin: s.stdin,
Stdout: s.stdout, Stdout: s.stdout,
Stderr: s.stderr, Stderr: s.stderr,
Labels: context.StringSlice("label"),
} }
) )
if context.Bool("attach") { if context.Bool("attach") {

View file

@ -40,6 +40,8 @@ type Container interface {
Checkpoint(Checkpoint) error Checkpoint(Checkpoint) error
// DeleteCheckpoint deletes the checkpoint for the provided name // DeleteCheckpoint deletes the checkpoint for the provided name
DeleteCheckpoint(name string) error DeleteCheckpoint(name string) error
// Labels are user provided labels for the container
Labels() []string
// Stats returns realtime container stats and resource information // Stats returns realtime container stats and resource information
// Stats() (*Stat, error) // OOM signals the channel if the container received an OOM notification // Stats() (*Stat, error) // OOM signals the channel if the container received an OOM notification
// OOM() (<-chan struct{}, error) // OOM() (<-chan struct{}, error)
@ -67,11 +69,12 @@ func NewStdio(stdin, stdout, stderr string) Stdio {
} }
// New returns a new container // New returns a new container
func New(root, id, bundle string) (Container, error) { func New(root, id, bundle string, labels []string) (Container, error) {
c := &container{ c := &container{
root: root, root: root,
id: id, id: id,
bundle: bundle, bundle: bundle,
labels: labels,
processes: make(map[string]*process), processes: make(map[string]*process),
} }
if err := os.Mkdir(filepath.Join(root, id), 0755); err != nil { if err := os.Mkdir(filepath.Join(root, id), 0755); err != nil {
@ -84,6 +87,7 @@ func New(root, id, bundle string) (Container, error) {
defer f.Close() defer f.Close()
if err := json.NewEncoder(f).Encode(state{ if err := json.NewEncoder(f).Encode(state{
Bundle: bundle, Bundle: bundle,
Labels: labels,
}); err != nil { }); err != nil {
return nil, err return nil, err
} }
@ -104,6 +108,7 @@ func Load(root, id string) (Container, error) {
root: root, root: root,
id: id, id: id,
bundle: s.Bundle, bundle: s.Bundle,
labels: s.Labels,
processes: make(map[string]*process), processes: make(map[string]*process),
} }
dirs, err := ioutil.ReadDir(filepath.Join(root, id)) dirs, err := ioutil.ReadDir(filepath.Join(root, id))
@ -149,6 +154,7 @@ type container struct {
bundle string bundle string
processes map[string]*process processes map[string]*process
stdio Stdio stdio Stdio
labels []string
} }
func (c *container) ID() string { func (c *container) ID() string {
@ -159,6 +165,10 @@ func (c *container) Path() string {
return c.bundle return c.bundle
} }
func (c *container) Labels() []string {
return c.labels
}
func (c *container) Start(checkpoint string, s Stdio) (Process, error) { func (c *container) Start(checkpoint string, s Stdio) (Process, error) {
processRoot := filepath.Join(c.root, c.id, InitProcessID) processRoot := filepath.Join(c.root, c.id, InitProcessID)
if err := os.Mkdir(processRoot, 0755); err != nil { if err := os.Mkdir(processRoot, 0755); err != nil {

View file

@ -37,6 +37,7 @@ const (
type state struct { type state struct {
Bundle string `json:"bundle"` Bundle string `json:"bundle"`
Labels []string `json:"labels"`
Stdin string `json:"stdin"` Stdin string `json:"stdin"`
Stdout string `json:"stdout"` Stdout string `json:"stdout"`
Stderr string `json:"stderr"` Stderr string `json:"stderr"`

View file

@ -12,7 +12,7 @@ type StartEvent struct {
func (h *StartEvent) Handle(e *Event) error { func (h *StartEvent) Handle(e *Event) error {
start := time.Now() start := time.Now()
container, err := runtime.New(h.s.stateDir, e.ID, e.BundlePath) container, err := runtime.New(h.s.stateDir, e.ID, e.BundlePath, e.Labels)
if err != nil { if err != nil {
return err return err
} }

View file

@ -64,6 +64,7 @@ type Event struct {
ResizeTty bool ResizeTty bool
Width int Width int
Height int Height int
Labels []string
} }
type Handler interface { type Handler interface {