{"action":"created","comment":{"url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/comments/70353297","id":70353297,"diff_hunk":"@@ -0,0 +1,94 @@\n+# Runtime Command Line Interface\n+\n+This document specifies the command line syntax for runtime operations defined in the [Runtime and Lifecycle](runtime.md) specification.\n+It is STRONGLY RECOMMENDED that implementations adhere to the command line definition defined below to ensure interoperability.\n+This document will not duplicate the information/semantics specified in the [Runtime and Lifecycle](runtime.md) document, rather it just focuses on syntax of the command line.\n+\n+## Convention\n+\n+For the purpose of this document, the following syntactical conventions are used:\n+\n+* `[ ... ]` denotes an optional field\n+* `< ... >` denotes a substitution field. \n+The word(s), or phrase, within the `<>` describes the information to be passed-in.\n+\n+## General Format and Behavior\n+\n+The general format of all commands MUST be:\n+```\n+runtime [global-options] action [action-specific-options] [arguments]\n+```\n+\n+Upon successful running of an action, the exit code MUST be zero.\n+\n+If there is an error during the running of an action, then:\n+* the exit code MUST be non-zero\n+* any error text MUST be displayed on stderr\n+* the state of the environment MUST be the same as if the action was never attempted (modulo any possible trivial ancillary changes such as logging)\n+\n+### Global Options\n+\n+Global options are ones that apply to all actions.\n+This specification doesn't define any global options.\n+Implementation MAY define their own.\n+\n+### Action Specific Options\n+\n+All actions MUST support the `--help` action-specific-option, which:\n+* MUST display some help text to stdout\n+* MUST NOT perform the `action` itself\n+* MUST have an exit code of zero if the help text is successfully displayed\n+\n+Implementations MAY define their own action-specific options.\n+\n+## Actions\n+\n+This section defines the actions defined by this specification.\n+\n+### State\n+\n+Format: `runtime [global-options] state [options] <container-id>`\n+\n+Options: None\n+\n+This action MUST display the state of the specific container to stdout.\n+Unless otherwise specified by the user, the format of the state MUST be in JSON.\n+\n+See [Query State](runtime.md#query-state).\n+\n+### Create\n+\n+Format: `runtime [global-options] create [options] <container-id>`\n+\n+Options:\n+* `-b <dir>`,  `--bundle <dir>` The path to the root of the bundle directory. If not specified the default value MUST be the current working directory.\n+* `--console <path>` The PTY slave path for the newly created container.\n+* `--pid-file <path>` The file path into which the process ID is written. If not specified then a file MUST not be created.","path":"cmd.md","position":66,"original_position":66,"commit_id":"d6d5d0d7cd650a91632bff062ca2a8feb5742725","original_commit_id":"d6d5d0d7cd650a91632bff062ca2a8feb5742725","user":{"login":"wking","id":209920,"avatar_url":"https://avatars.githubusercontent.com/u/209920?v=3","gravatar_id":"","url":"https://api.github.com/users/wking","html_url":"https://github.com/wking","followers_url":"https://api.github.com/users/wking/followers","following_url":"https://api.github.com/users/wking/following{/other_user}","gists_url":"https://api.github.com/users/wking/gists{/gist_id}","starred_url":"https://api.github.com/users/wking/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wking/subscriptions","organizations_url":"https://api.github.com/users/wking/orgs","repos_url":"https://api.github.com/users/wking/repos","events_url":"https://api.github.com/users/wking/events{/privacy}","received_events_url":"https://api.github.com/users/wking/received_events","type":"User","site_admin":false},"body":"I'm guessing this is to enable the [`PR_SET_CHILD_SUBREAPER` magic][1]?  That approach is not portable (and maybe container PIDs are not even portable, #459).  I'd rather see a [portable way to collect the child exit code][2], and #508 is my attempt at groundwork for that.\r\n\r\n[1]: https://github.com/opencontainers/runc/pull/827#discussion_r63598816\r\n[2]: https://github.com/opencontainers/runtime-spec/pull/513#issuecomment-230978790","created_at":"2016-07-11T23:06:54Z","updated_at":"2016-07-11T23:06:54Z","html_url":"https://github.com/opencontainers/runtime-spec/pull/511#discussion_r70353297","pull_request_url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511","_links":{"self":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/comments/70353297"},"html":{"href":"https://github.com/opencontainers/runtime-spec/pull/511#discussion_r70353297"},"pull_request":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511"}}},"pull_request":{"url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511","id":76351445,"html_url":"https://github.com/opencontainers/runtime-spec/pull/511","diff_url":"https://github.com/opencontainers/runtime-spec/pull/511.diff","patch_url":"https://github.com/opencontainers/runtime-spec/pull/511.patch","issue_url":"https://api.github.com/repos/opencontainers/runtime-spec/issues/511","number":511,"state":"open","locked":false,"title":"Add initial pass at a cmd line spec","user":{"login":"duglin","id":1944671,"avatar_url":"https://avatars.githubusercontent.com/u/1944671?v=3","gravatar_id":"","url":"https://api.github.com/users/duglin","html_url":"https://github.com/duglin","followers_url":"https://api.github.com/users/duglin/followers","following_url":"https://api.github.com/users/duglin/following{/other_user}","gists_url":"https://api.github.com/users/duglin/gists{/gist_id}","starred_url":"https://api.github.com/users/duglin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duglin/subscriptions","organizations_url":"https://api.github.com/users/duglin/orgs","repos_url":"https://api.github.com/users/duglin/repos","events_url":"https://api.github.com/users/duglin/events{/privacy}","received_events_url":"https://api.github.com/users/duglin/received_events","type":"User","site_admin":false},"body":"Gives us something to shoot arrows at  :-)\r\n\r\nSigned-off-by: Doug Davis <dug@us.ibm.com>","created_at":"2016-07-05T22:10:30Z","updated_at":"2016-07-11T23:06:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8277e9443a3ce3f1ba19cfc2287e9c4c09ed7243","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511/commits","review_comments_url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511/comments","review_comment_url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/comments{/number}","comments_url":"https://api.github.com/repos/opencontainers/runtime-spec/issues/511/comments","statuses_url":"https://api.github.com/repos/opencontainers/runtime-spec/statuses/d6d5d0d7cd650a91632bff062ca2a8feb5742725","head":{"label":"duglin:cmdline","ref":"cmdline","sha":"d6d5d0d7cd650a91632bff062ca2a8feb5742725","user":{"login":"duglin","id":1944671,"avatar_url":"https://avatars.githubusercontent.com/u/1944671?v=3","gravatar_id":"","url":"https://api.github.com/users/duglin","html_url":"https://github.com/duglin","followers_url":"https://api.github.com/users/duglin/followers","following_url":"https://api.github.com/users/duglin/following{/other_user}","gists_url":"https://api.github.com/users/duglin/gists{/gist_id}","starred_url":"https://api.github.com/users/duglin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duglin/subscriptions","organizations_url":"https://api.github.com/users/duglin/orgs","repos_url":"https://api.github.com/users/duglin/repos","events_url":"https://api.github.com/users/duglin/events{/privacy}","received_events_url":"https://api.github.com/users/duglin/received_events","type":"User","site_admin":false},"repo":{"id":43553626,"name":"runtime-spec","full_name":"duglin/runtime-spec","owner":{"login":"duglin","id":1944671,"avatar_url":"https://avatars.githubusercontent.com/u/1944671?v=3","gravatar_id":"","url":"https://api.github.com/users/duglin","html_url":"https://github.com/duglin","followers_url":"https://api.github.com/users/duglin/followers","following_url":"https://api.github.com/users/duglin/following{/other_user}","gists_url":"https://api.github.com/users/duglin/gists{/gist_id}","starred_url":"https://api.github.com/users/duglin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duglin/subscriptions","organizations_url":"https://api.github.com/users/duglin/orgs","repos_url":"https://api.github.com/users/duglin/repos","events_url":"https://api.github.com/users/duglin/events{/privacy}","received_events_url":"https://api.github.com/users/duglin/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/duglin/runtime-spec","description":"Open Container Specifications","fork":true,"url":"https://api.github.com/repos/duglin/runtime-spec","forks_url":"https://api.github.com/repos/duglin/runtime-spec/forks","keys_url":"https://api.github.com/repos/duglin/runtime-spec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/duglin/runtime-spec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/duglin/runtime-spec/teams","hooks_url":"https://api.github.com/repos/duglin/runtime-spec/hooks","issue_events_url":"https://api.github.com/repos/duglin/runtime-spec/issues/events{/number}","events_url":"https://api.github.com/repos/duglin/runtime-spec/events","assignees_url":"https://api.github.com/repos/duglin/runtime-spec/assignees{/user}","branches_url":"https://api.github.com/repos/duglin/runtime-spec/branches{/branch}","tags_url":"https://api.github.com/repos/duglin/runtime-spec/tags","blobs_url":"https://api.github.com/repos/duglin/runtime-spec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/duglin/runtime-spec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/duglin/runtime-spec/git/refs{/sha}","trees_url":"https://api.github.com/repos/duglin/runtime-spec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/duglin/runtime-spec/statuses/{sha}","languages_url":"https://api.github.com/repos/duglin/runtime-spec/languages","stargazers_url":"https://api.github.com/repos/duglin/runtime-spec/stargazers","contributors_url":"https://api.github.com/repos/duglin/runtime-spec/contributors","subscribers_url":"https://api.github.com/repos/duglin/runtime-spec/subscribers","subscription_url":"https://api.github.com/repos/duglin/runtime-spec/subscription","commits_url":"https://api.github.com/repos/duglin/runtime-spec/commits{/sha}","git_commits_url":"https://api.github.com/repos/duglin/runtime-spec/git/commits{/sha}","comments_url":"https://api.github.com/repos/duglin/runtime-spec/comments{/number}","issue_comment_url":"https://api.github.com/repos/duglin/runtime-spec/issues/comments{/number}","contents_url":"https://api.github.com/repos/duglin/runtime-spec/contents/{+path}","compare_url":"https://api.github.com/repos/duglin/runtime-spec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/duglin/runtime-spec/merges","archive_url":"https://api.github.com/repos/duglin/runtime-spec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/duglin/runtime-spec/downloads","issues_url":"https://api.github.com/repos/duglin/runtime-spec/issues{/number}","pulls_url":"https://api.github.com/repos/duglin/runtime-spec/pulls{/number}","milestones_url":"https://api.github.com/repos/duglin/runtime-spec/milestones{/number}","notifications_url":"https://api.github.com/repos/duglin/runtime-spec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/duglin/runtime-spec/labels{/name}","releases_url":"https://api.github.com/repos/duglin/runtime-spec/releases{/id}","deployments_url":"https://api.github.com/repos/duglin/runtime-spec/deployments","created_at":"2015-10-02T13:15:03Z","updated_at":"2016-03-31T12:00:32Z","pushed_at":"2016-07-07T02:34:42Z","git_url":"git://github.com/duglin/runtime-spec.git","ssh_url":"git@github.com:duglin/runtime-spec.git","clone_url":"https://github.com/duglin/runtime-spec.git","svn_url":"https://github.com/duglin/runtime-spec","homepage":"http://www.opencontainers.org","size":582,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"opencontainers:master","ref":"master","sha":"b45aa77484bb771fc50498020063abcbc9b5f4c2","user":{"login":"opencontainers","id":12563465,"avatar_url":"https://avatars.githubusercontent.com/u/12563465?v=3","gravatar_id":"","url":"https://api.github.com/users/opencontainers","html_url":"https://github.com/opencontainers","followers_url":"https://api.github.com/users/opencontainers/followers","following_url":"https://api.github.com/users/opencontainers/following{/other_user}","gists_url":"https://api.github.com/users/opencontainers/gists{/gist_id}","starred_url":"https://api.github.com/users/opencontainers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencontainers/subscriptions","organizations_url":"https://api.github.com/users/opencontainers/orgs","repos_url":"https://api.github.com/users/opencontainers/repos","events_url":"https://api.github.com/users/opencontainers/events{/privacy}","received_events_url":"https://api.github.com/users/opencontainers/received_events","type":"Organization","site_admin":false},"repo":{"id":36960293,"name":"runtime-spec","full_name":"opencontainers/runtime-spec","owner":{"login":"opencontainers","id":12563465,"avatar_url":"https://avatars.githubusercontent.com/u/12563465?v=3","gravatar_id":"","url":"https://api.github.com/users/opencontainers","html_url":"https://github.com/opencontainers","followers_url":"https://api.github.com/users/opencontainers/followers","following_url":"https://api.github.com/users/opencontainers/following{/other_user}","gists_url":"https://api.github.com/users/opencontainers/gists{/gist_id}","starred_url":"https://api.github.com/users/opencontainers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencontainers/subscriptions","organizations_url":"https://api.github.com/users/opencontainers/orgs","repos_url":"https://api.github.com/users/opencontainers/repos","events_url":"https://api.github.com/users/opencontainers/events{/privacy}","received_events_url":"https://api.github.com/users/opencontainers/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opencontainers/runtime-spec","description":"OCI Runtime Specification","fork":false,"url":"https://api.github.com/repos/opencontainers/runtime-spec","forks_url":"https://api.github.com/repos/opencontainers/runtime-spec/forks","keys_url":"https://api.github.com/repos/opencontainers/runtime-spec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opencontainers/runtime-spec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opencontainers/runtime-spec/teams","hooks_url":"https://api.github.com/repos/opencontainers/runtime-spec/hooks","issue_events_url":"https://api.github.com/repos/opencontainers/runtime-spec/issues/events{/number}","events_url":"https://api.github.com/repos/opencontainers/runtime-spec/events","assignees_url":"https://api.github.com/repos/opencontainers/runtime-spec/assignees{/user}","branches_url":"https://api.github.com/repos/opencontainers/runtime-spec/branches{/branch}","tags_url":"https://api.github.com/repos/opencontainers/runtime-spec/tags","blobs_url":"https://api.github.com/repos/opencontainers/runtime-spec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opencontainers/runtime-spec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opencontainers/runtime-spec/git/refs{/sha}","trees_url":"https://api.github.com/repos/opencontainers/runtime-spec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opencontainers/runtime-spec/statuses/{sha}","languages_url":"https://api.github.com/repos/opencontainers/runtime-spec/languages","stargazers_url":"https://api.github.com/repos/opencontainers/runtime-spec/stargazers","contributors_url":"https://api.github.com/repos/opencontainers/runtime-spec/contributors","subscribers_url":"https://api.github.com/repos/opencontainers/runtime-spec/subscribers","subscription_url":"https://api.github.com/repos/opencontainers/runtime-spec/subscription","commits_url":"https://api.github.com/repos/opencontainers/runtime-spec/commits{/sha}","git_commits_url":"https://api.github.com/repos/opencontainers/runtime-spec/git/commits{/sha}","comments_url":"https://api.github.com/repos/opencontainers/runtime-spec/comments{/number}","issue_comment_url":"https://api.github.com/repos/opencontainers/runtime-spec/issues/comments{/number}","contents_url":"https://api.github.com/repos/opencontainers/runtime-spec/contents/{+path}","compare_url":"https://api.github.com/repos/opencontainers/runtime-spec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opencontainers/runtime-spec/merges","archive_url":"https://api.github.com/repos/opencontainers/runtime-spec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opencontainers/runtime-spec/downloads","issues_url":"https://api.github.com/repos/opencontainers/runtime-spec/issues{/number}","pulls_url":"https://api.github.com/repos/opencontainers/runtime-spec/pulls{/number}","milestones_url":"https://api.github.com/repos/opencontainers/runtime-spec/milestones{/number}","notifications_url":"https://api.github.com/repos/opencontainers/runtime-spec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opencontainers/runtime-spec/labels{/name}","releases_url":"https://api.github.com/repos/opencontainers/runtime-spec/releases{/id}","deployments_url":"https://api.github.com/repos/opencontainers/runtime-spec/deployments","created_at":"2015-06-05T23:30:10Z","updated_at":"2016-07-11T16:21:59Z","pushed_at":"2016-07-07T07:43:09Z","git_url":"git://github.com/opencontainers/runtime-spec.git","ssh_url":"git@github.com:opencontainers/runtime-spec.git","clone_url":"https://github.com/opencontainers/runtime-spec.git","svn_url":"https://github.com/opencontainers/runtime-spec","homepage":"http://www.opencontainers.org","size":1970,"stargazers_count":727,"watchers_count":727,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":124,"mirror_url":null,"open_issues_count":43,"forks":124,"open_issues":43,"watchers":727,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511"},"html":{"href":"https://github.com/opencontainers/runtime-spec/pull/511"},"issue":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/issues/511"},"comments":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/issues/511/comments"},"review_comments":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511/comments"},"review_comment":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/pulls/511/commits"},"statuses":{"href":"https://api.github.com/repos/opencontainers/runtime-spec/statuses/d6d5d0d7cd650a91632bff062ca2a8feb5742725"}}}}
{"actor":{"display_login":"wking"}}