You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This User structure does not map to the cleanliness of the current go
structure, but will allow the definition to be all in one place,
regardless of the host that is doing the compilation.
Switching field rules to `optional` for now. Per vish and the docs,
https://developers.google.com/protocol-buffers/docs/proto?csw=1#specifying-field-rules
"! Required Is Forever"
Also add a `make py` and `make all` target.
Signed-off-by: Vincent Batts <[email protected]>
// Spec is the base configuration for the container. It specifies platform
4
6
// independent configuration.
5
7
messageSpec {
6
8
// Version is the version of the specification that is supported.
7
-
requiredstringVersion=1;
9
+
optionalstringVersion=1;
8
10
// Platform is the host information for OS and Arch.
9
-
requiredPlatformPlatform=2; // [default=77];
11
+
optionalPlatformPlatform=2; // [default=77];
10
12
// Process is the container's main process.
11
-
requiredProcessProcess=3;
13
+
optionalProcessProcess=3;
12
14
// Root is the root information for the container's filesystem.
13
-
requiredRootRoot=4;
15
+
optionalRootRoot=4;
14
16
// Hostname is the container's host name.
15
-
requiredstringHostname=5;
17
+
optionalstringHostname=5;
16
18
// Mounts profile configuration for adding mounts to the container's filesystem.
17
19
repeatedMountPointMounts=6;
18
20
}
@@ -21,39 +23,60 @@ message Spec {
21
23
// is created for.
22
24
messagePlatform {
23
25
// OS is the operating system.
24
-
requiredstringOS=1;
26
+
optionalstringOS=1;
25
27
// Arch is the architecture
26
-
requiredstringArch=2;
28
+
optionalstringArch=2;
27
29
}
28
30
29
31
// Process contains information to start a specific application inside the container.
30
32
messageProcess {
31
33
// Terminal creates an interactive terminal for the container.
32
-
requiredboolTerminal=1;
34
+
optionalboolTerminal=1;
33
35
// User specifies user information for the process.
34
-
// TODO(vbatts) figure out platform dependent types
35
-
//required User User = 2;
36
+
optionalUserUser=2;
36
37
// Args specifies the binary and arguments for the application to execute.
37
38
repeatedstringArgs=3;
38
39
// Env populates the process environment for the process.
39
40
repeatedstringEnv=4;
40
41
// Cwd is the current working directory for the process and must be
41
42
// relative to the container's root.
42
-
requiredstringCwd=5;
43
+
optionalstringCwd=5;
44
+
}
45
+
46
+
enumPlatformType {
47
+
LINUX=1;
48
+
}
49
+
50
+
// User specifies user information for the process.
51
+
messageUser {
52
+
// Type so that receivers of this message can `switch` for the fields expected
53
+
optionalPlatformTypeType=1 [default = LINUX];
54
+
// LinuxUserFields are to be used when Type is LINUX
55
+
optionallinuxUserFieldsLinuxUserFields=2;
56
+
}
57
+
58
+
// User specifies linux specific user and group information for the container's
59
+
// main process.
60
+
messagelinuxUserFields {
61
+
// UID is the user id.
62
+
optionalint32UID=1;
63
+
// GID is the group id.
64
+
optionalint32GID=2;
65
+
repeatedint32AdditionalGids=3;
43
66
}
44
67
45
68
// Root contains information about the container's root filesystem on the host.
46
69
messageRoot {
47
70
// Path is the absolute path to the container's root filesystem.
48
-
requiredstringPath=1;
71
+
optionalstringPath=1;
49
72
// Readonly makes the root filesystem for the container readonly before the process is executed.
50
-
requiredboolReadonly=2;
73
+
optionalboolReadonly=2;
51
74
}
52
75
53
76
// MountPoint describes a directory that may be fullfilled by a mount in the runtime.json.
54
77
messageMountPoint {
55
78
// Name is a unique descriptive identifier for this mount point.
56
-
requiredstringName=1;
79
+
optionalstringName=1;
57
80
// Path specifies the path of the mount. The path and child directories MUST exist, a runtime MUST NOT create directories automatically to a mount point.
0 commit comments