{"action":"created","issue":{"url":"https://api.github.com/repos/opencontainers/ocitools/issues/66","repository_url":"https://api.github.com/repos/opencontainers/ocitools","labels_url":"https://api.github.com/repos/opencontainers/ocitools/issues/66/labels{/name}","comments_url":"https://api.github.com/repos/opencontainers/ocitools/issues/66/comments","events_url":"https://api.github.com/repos/opencontainers/ocitools/issues/66/events","html_url":"https://github.com/opencontainers/ocitools/issues/66","id":154667740,"number":66,"title":"runtimespec VS ocitools","user":{"login":"liangchenye","id":13341875,"avatar_url":"https://avatars.githubusercontent.com/u/13341875?v=3","gravatar_id":"","url":"https://api.github.com/users/liangchenye","html_url":"https://github.com/liangchenye","followers_url":"https://api.github.com/users/liangchenye/followers","following_url":"https://api.github.com/users/liangchenye/following{/other_user}","gists_url":"https://api.github.com/users/liangchenye/gists{/gist_id}","starred_url":"https://api.github.com/users/liangchenye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/liangchenye/subscriptions","organizations_url":"https://api.github.com/users/liangchenye/orgs","repos_url":"https://api.github.com/users/liangchenye/repos","events_url":"https://api.github.com/users/liangchenye/events{/privacy}","received_events_url":"https://api.github.com/users/liangchenye/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2016-05-13T09:14:54Z","updated_at":"2016-05-23T02:34:45Z","closed_at":null,"body":"## [Filesystem bundle](https://github.com/opencontainers/runtime-spec/blob/master/bundle.md)\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L59) config.json : This REQUIRED file, which MUST be named config.json.\r\n- [ ] :lock:   [discuss](https://github.com/opencontainers/ocitools/issues/66#issuecomment-219103747) When the bundle is packaged up for distribution, this directory MUST be included.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L72) This directory MUST be referenced from within the config.json file.\r\n\r\n## [Runtime and Lifecycle](https://github.com/opencontainers/runtime-spec/blob/master/runtime.md)\r\n- [x] :first_quarter_moon: [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/cmd/runtimetest/main.go) The container's runtime environment MUST be created according to the configuration in config.json.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/cmd/runtimetest/main.go#L22) Any updates to config.json after container is running MUST not affect the container.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) The prestart hooks MUST be invoked by the runtime.\r\n      If any prestart hook fails, then the container MUST be stopped and the lifecycle continues at step 8.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) The user specified process MUST be executed in the container.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) poststart hooks MUST be invoked by the runtime.\r\n       If any poststart hook fails, then the container MUST be stopped and the lifecycle continues at step 8\r\n- [ ] The container MUST be destroyed by undoing the steps performed during create phase (step 2)\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) The poststop hooks MUST be invoked by the runtime and errors, if any, MAY be logged.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) Query State: state <container-id>\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) This operation MUST generate an error if it is not provided the ID of a container.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) This operation MUST return the state of a container as specified in the State section. In particular, the state MUST be serialized as JSON.\r\n\r\n### Start :lock:  [discuss](https://github.com/opencontainers/ocitools/issues/66#issuecomment-219103747)\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) This operation MUST generate an error if it is not provided a path to the bundle and the container ID to associate with the container.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) If the ID provided is not unique across all containers within the scope of the runtime, or is not valid in any other way, the implementation MUST generate an error.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/cmd/runtimetest/main.go#L22) Using the data in config.json, that are in the bundle's directory, this operation MUST create a new container.This includes creating the relevant namespaces, resource limits, etc and configuring the appropriate capabilities for the container.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/cmd/runtimetest/main.go#L36-L99) A new process within the scope of the container MUST be created as specified by the config.json file otherwise an error MUST be generated.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/61) Attempting to start an already running container MUST have no effect on the container and MUST generate an error.\t\r\n\r\n### Stop :lock: [discuss](https://github.com/opencontainers/ocitools/issues/66#issuecomment-219103747)\r\n- [ ] This operation MUST generate an error if it is not provided the container ID.\r\n- [ ] This operation MUST stop and delete a running container.\r\n- [ ] Stopping a container MUST stop all of the processes running within the scope of the container.\r\n- [ ] Deleting a container MUST delete the associated namespaces and resources associated with the container.\r\n- [ ] Once a container is deleted, its id MAY be used by subsequent containers.\r\n- [ ] Attempting to stop a container that is not running MUST have no effect on the container and MUST generate an error.\t\r\n \r\n## [Configuration](https://github.com/opencontainers/runtime-spec/blob/master/config.md)\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L59) The container's top-level directory MUST contain a configuration file called config.json.  (dup)\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L93-L98)  ociVersion (string, required) must be in SemVer v2.0.0 format.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L72) path (string, required) Specifies the path to the root filesystem for the container, relative to the path where the manifest is. A directory MUST exist at the relative path declared by the field.\r\n- [ ] readonly (bool, optional) If true then the root filesystem MUST be read-only inside the container. \r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/generate.go#L721) readonly Defaults to false.\r\n- [ ] The runtime MUST mount entries in the listed order.\r\n- [ ] Destination of mount point: path inside container. For the Windows operating system, one mount destination MUST NOT be nested within another mount. (Ex: c:\\foo and c:\\foo\\bar).\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L395) destination (required) \r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L395) mounts type (string, required) \r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L395) source (string, required) \r\n- [ ] Mounts options (list of strings, optional) in the fstab format https://wiki.archlinux.org/index.php/Fstab.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/generate.go#L724)  terminal (bool, optional) Defaults to false\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L136)  process cwd (string, required) is the working directory that will be set for the executable. This value MUST be an absolute path.\r\n- [x]  [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L234-L245) process env (array of strings, optional) Elements in the array are specified as Strings in the form \"KEY=value\". The left hand side must consist solely of letters, digits, and underscores _ .\r\n- [ ] :question:   process args (array of strings, required) executable to launch and any flags as an array. The executable is the first element and must be available at the given path inside of the rootfs. If the executable path is not an absolute path then the search $PATH is interpreted to find the executable.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L111-133) Platform-specific configuration\tos (string, required)  $GOOS.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L111-133) Platform-specific configuration\tarch (string, required)  $GOARCH.\r\n- [ ] Hooks\tHooks MUST be called in the listed order.\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L395)  Hooks path is required for a hook, args and env are optional.\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/49) Hooks paths are absolute \r\n\r\n## [Linux-specific Container Configuration](https://github.com/opencontainers/runtime-spec/blob/master/config-linux.md)\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L148) capabilities (array of strings, optional)  Valid values are the strings for capabilities defined in the man page\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L154) rlimits (array of rlimits, optional)  Valid values for the 'type' field are the resources defined in the man page.\r\n- [ ] Default File Systems\tThe following filesystems MUST be made available in each application's filesystem \r\n```\r\nPath\tType\r\n/proc\tprocfs\r\n/sys\tsysfs\r\n/dev/pts\tdevpts\r\n/dev/shm\ttmpfs\r\n```\r\n- [ ] [WIP](https://github.com/opencontainers/ocitools/pull/72) hostname (optional) on Linux , you can only set this if your bundle creates a new UTS namespace\r\n- [ ] Namespaces Also, when a path is specified, a runtime MUST assume that the setup for that particular namespace has already been done and error out if the config specifies anything else related to that namespace.\r\n- [ ] devices is an array specifying the list of devices that MUST be available in the container.In addition to any devices configured with this setting, the runtime MUST also supply\r\n- [ ] Control groups \tThe runtime MUST apply entries in the listed order.\r\n- [ ] Control groups\tYou must specify at least one of weight or leafWeight in a given entry, and can specify both.\tPlaned\r\n- [x] [code](https://github.com/opencontainers/ocitools/blob/a637b56baa7229f1da25d8f1bf52f1da185135cd/validate.go#L64) JSON\tAll configuration JSON MUST be encoded in UTF-8."},"comment":{"url":"https://api.github.com/repos/opencontainers/ocitools/issues/comments/220875768","html_url":"https://github.com/opencontainers/ocitools/issues/66#issuecomment-220875768","issue_url":"https://api.github.com/repos/opencontainers/ocitools/issues/66","id":220875768,"user":{"login":"liangchenye","id":13341875,"avatar_url":"https://avatars.githubusercontent.com/u/13341875?v=3","gravatar_id":"","url":"https://api.github.com/users/liangchenye","html_url":"https://github.com/liangchenye","followers_url":"https://api.github.com/users/liangchenye/followers","following_url":"https://api.github.com/users/liangchenye/following{/other_user}","gists_url":"https://api.github.com/users/liangchenye/gists{/gist_id}","starred_url":"https://api.github.com/users/liangchenye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/liangchenye/subscriptions","organizations_url":"https://api.github.com/users/liangchenye/orgs","repos_url":"https://api.github.com/users/liangchenye/repos","events_url":"https://api.github.com/users/liangchenye/events{/privacy}","received_events_url":"https://api.github.com/users/liangchenye/received_events","type":"User","site_admin":false},"created_at":"2016-05-23T02:34:45Z","updated_at":"2016-05-23T02:34:45Z","body":"updated:\r\n1. using permanent URLs as @wking suggested\r\n2. mark utf8/cwd/env tasks to done"}}
{"actor":{"display_login":"liangchenye"}}