sandbox: add Sandboxer field to sandbox metadata
Signed-off-by: Abel Feng <fshb1988@gmail.com>
This commit is contained in:
@@ -35,6 +35,7 @@ func ToProto(sandbox *Sandbox) *types.Sandbox {
|
||||
Name: sandbox.Runtime.Name,
|
||||
Options: protobuf.FromAny(sandbox.Runtime.Options),
|
||||
},
|
||||
Sandboxer: sandbox.Sandboxer,
|
||||
Labels: sandbox.Labels,
|
||||
CreatedAt: protobuf.ToTimestamp(sandbox.CreatedAt),
|
||||
UpdatedAt: protobuf.ToTimestamp(sandbox.UpdatedAt),
|
||||
@@ -61,6 +62,7 @@ func FromProto(sandboxpb *types.Sandbox) Sandbox {
|
||||
Labels: sandboxpb.Labels,
|
||||
Runtime: runtime,
|
||||
Spec: sandboxpb.Spec,
|
||||
Sandboxer: sandboxpb.Sandboxer,
|
||||
CreatedAt: protobuf.FromTimestamp(sandboxpb.CreatedAt),
|
||||
UpdatedAt: protobuf.FromTimestamp(sandboxpb.UpdatedAt),
|
||||
Extensions: extensions,
|
||||
|
||||
@@ -35,6 +35,8 @@ type Sandbox struct {
|
||||
Runtime RuntimeOpts
|
||||
// Spec carries the runtime specification used to implement the sandbox
|
||||
Spec typeurl.Any
|
||||
// Sandboxer is the sandbox controller who manages the sandbox
|
||||
Sandboxer string
|
||||
// CreatedAt is the time at which the sandbox was created
|
||||
CreatedAt time.Time
|
||||
// UpdatedAt is the time at which the sandbox was updated
|
||||
|
||||
Reference in New Issue
Block a user