{"action":"created","comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments/27737682","id":27737682,"diff_hunk":"@@ -0,0 +1,124 @@\n+/*\n+Copyright 2015 Google Inc. All rights reserved.\n+\n+Licensed under the Apache License, Version 2.0 (the \"License\");\n+you may not use this file except in compliance with the License.\n+You may obtain a copy of the License at\n+\n+    http://www.apache.org/licenses/LICENSE-2.0\n+\n+Unless required by applicable law or agreed to in writing, software\n+distributed under the License is distributed on an \"AS IS\" BASIS,\n+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+See the License for the specific language governing permissions and\n+limitations under the License.\n+*/\n+\n+package e2e\n+\n+import (\n+\t\"github.com/GoogleCloudPlatform/kubernetes/pkg/api\"\n+\t\"github.com/GoogleCloudPlatform/kubernetes/pkg/client\"\n+\t\"github.com/GoogleCloudPlatform/kubernetes/pkg/util\"\n+\n+\t. \"github.com/onsi/ginkgo\"\n+)\n+\n+var _ = Describe(\"emptyDir\", func() {\n+\tvar (\n+\t\tc         *client.Client\n+\t\tpodClient client.PodInterface\n+\t)\n+\n+\tBeforeEach(func() {\n+\t\tvar err error\n+\t\tc, err = loadClient()\n+\t\texpectNoError(err)\n+\n+\t\tpodClient = c.Pods(api.NamespaceDefault)\n+\t})\n+\n+\tIt(\"should support tmpfs in emptyDir\", func() {\n+\t\tname := \"pod-\" + string(util.NewUUID())\n+\t\tpod := &api.Pod{\n+\t\t\tTypeMeta: api.TypeMeta{\n+\t\t\t\tKind:       \"Pod\",\n+\t\t\t\tAPIVersion: \"v1beta1\",\n+\t\t\t},\n+\t\t\tObjectMeta: api.ObjectMeta{\n+\t\t\t\tName: name,\n+\t\t\t},\n+\t\t\tSpec: api.PodSpec{\n+\t\t\t\tContainers: []api.Container{\n+\t\t\t\t\t{\n+\t\t\t\t\t\tName:  \"mount-test\",\n+\t\t\t\t\t\tImage: \"kubernetes/mounttest:0.1\",\n+\t\t\t\t\t\tArgs:  []string{\"--fs_type=/testvol\"},\n+\t\t\t\t\t\tVolumeMounts: []api.VolumeMount{\n+\t\t\t\t\t\t\t{\n+\t\t\t\t\t\t\t\tName:      \"testvol\",\n+\t\t\t\t\t\t\t\tMountPath: \"/testvol\",\n+\t\t\t\t\t\t\t},\n+\t\t\t\t\t\t},\n+\t\t\t\t\t},\n+\t\t\t\t},\n+\t\t\t\tVolumes: []api.Volume{\n+\t\t\t\t\t{\n+\t\t\t\t\t\tName: \"testvol\",\n+\t\t\t\t\t\tVolumeSource: api.VolumeSource{\n+\t\t\t\t\t\t\tEmptyDir: &api.EmptyDirVolumeSource{\n+\t\t\t\t\t\t\t\tMedium: api.StorageTypeMemory,\n+\t\t\t\t\t\t\t},\n+\t\t\t\t\t\t},\n+\t\t\t\t\t},\n+\t\t\t\t},\n+\t\t\t},\n+\t\t}\n+\n+\t\ttestContainerOutput(\"tmpfs mount for emptydir\", c, pod, []string{\n+\t\t\t\"mount type: tmpfs\",\n+\t\t})\n+\t})\n+\n+\tIt(\"should be readable and writeable if we requested R/W on tmpfs\", func() {\n+\t\tname := \"pod-\" + string(util.NewUUID())\n+\t\tpod := &api.Pod{\n+\t\t\tTypeMeta: api.TypeMeta{\n+\t\t\t\tKind:       \"Pod\",\n+\t\t\t\tAPIVersion: \"v1beta1\",\n+\t\t\t},\n+\t\t\tObjectMeta: api.ObjectMeta{\n+\t\t\t\tName: name,\n+\t\t\t},\n+\t\t\tSpec: api.PodSpec{\n+\t\t\t\tContainers: []api.Container{\n+\t\t\t\t\t{\n+\t\t\t\t\t\tName:  \"mount-test\",\n+\t\t\t\t\t\tImage: \"kubernetes/mounttest:0.1\",\n+\t\t\t\t\t\tArgs:  []string{\"--rw_new_file=/testvol/testfile\"},","path":"test/e2e/empty_dir.go","position":98,"original_position":98,"commit_id":"6c58d1cff6a7b638f962b20b9808af376f88c70b","original_commit_id":"6c58d1cff6a7b638f962b20b9808af376f88c70b","user":{"login":"pmorie","id":366488,"avatar_url":"https://avatars.githubusercontent.com/u/366488?v=3","gravatar_id":"","url":"https://api.github.com/users/pmorie","html_url":"https://github.com/pmorie","followers_url":"https://api.github.com/users/pmorie/followers","following_url":"https://api.github.com/users/pmorie/following{/other_user}","gists_url":"https://api.github.com/users/pmorie/gists{/gist_id}","starred_url":"https://api.github.com/users/pmorie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pmorie/subscriptions","organizations_url":"https://api.github.com/users/pmorie/orgs","repos_url":"https://api.github.com/users/pmorie/repos","events_url":"https://api.github.com/users/pmorie/events{/privacy}","received_events_url":"https://api.github.com/users/pmorie/received_events","type":"User","site_admin":false},"body":"We should also check the filemode in this case and that the mount type is tmpfs.  You can pass multiple flags to the mounttest image entrypoint and check for the result of each one in the expected output.","created_at":"2015-04-03T16:11:42Z","updated_at":"2015-04-03T16:11:42Z","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166#discussion_r27737682","pull_request_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166","_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments/27737682"},"html":{"href":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166#discussion_r27737682"},"pull_request":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166"}}},"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166","id":32244868,"html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166","diff_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166.diff","patch_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/6166","number":6166,"state":"open","locked":false,"title":"Add e2e test for tmpfs","user":{"login":"jiangyaoguo","id":6777418,"avatar_url":"https://avatars.githubusercontent.com/u/6777418?v=3","gravatar_id":"","url":"https://api.github.com/users/jiangyaoguo","html_url":"https://github.com/jiangyaoguo","followers_url":"https://api.github.com/users/jiangyaoguo/followers","following_url":"https://api.github.com/users/jiangyaoguo/following{/other_user}","gists_url":"https://api.github.com/users/jiangyaoguo/gists{/gist_id}","starred_url":"https://api.github.com/users/jiangyaoguo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jiangyaoguo/subscriptions","organizations_url":"https://api.github.com/users/jiangyaoguo/orgs","repos_url":"https://api.github.com/users/jiangyaoguo/repos","events_url":"https://api.github.com/users/jiangyaoguo/events{/privacy}","received_events_url":"https://api.github.com/users/jiangyaoguo/received_events","type":"User","site_admin":false},"body":"Fix #5279\r\nThis test check the tmpfs volume use \"df\" cmd. Due to GCE does not support remote command execution, now the test can't run for GCE. Perhaps someone can tell me some other ideas to check test result.","created_at":"2015-03-30T16:47:37Z","updated_at":"2015-04-03T16:11:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"65c0c86974b3682f6b4b3cb7343144d87c4a20f9","assignee":{"login":"vmarmol","id":985208,"avatar_url":"https://avatars.githubusercontent.com/u/985208?v=3","gravatar_id":"","url":"https://api.github.com/users/vmarmol","html_url":"https://github.com/vmarmol","followers_url":"https://api.github.com/users/vmarmol/followers","following_url":"https://api.github.com/users/vmarmol/following{/other_user}","gists_url":"https://api.github.com/users/vmarmol/gists{/gist_id}","starred_url":"https://api.github.com/users/vmarmol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmarmol/subscriptions","organizations_url":"https://api.github.com/users/vmarmol/orgs","repos_url":"https://api.github.com/users/vmarmol/repos","events_url":"https://api.github.com/users/vmarmol/events{/privacy}","received_events_url":"https://api.github.com/users/vmarmol/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/6166/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/6c58d1cff6a7b638f962b20b9808af376f88c70b","head":{"label":"jiangyaoguo:master","ref":"master","sha":"6c58d1cff6a7b638f962b20b9808af376f88c70b","user":{"login":"jiangyaoguo","id":6777418,"avatar_url":"https://avatars.githubusercontent.com/u/6777418?v=3","gravatar_id":"","url":"https://api.github.com/users/jiangyaoguo","html_url":"https://github.com/jiangyaoguo","followers_url":"https://api.github.com/users/jiangyaoguo/followers","following_url":"https://api.github.com/users/jiangyaoguo/following{/other_user}","gists_url":"https://api.github.com/users/jiangyaoguo/gists{/gist_id}","starred_url":"https://api.github.com/users/jiangyaoguo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jiangyaoguo/subscriptions","organizations_url":"https://api.github.com/users/jiangyaoguo/orgs","repos_url":"https://api.github.com/users/jiangyaoguo/repos","events_url":"https://api.github.com/users/jiangyaoguo/events{/privacy}","received_events_url":"https://api.github.com/users/jiangyaoguo/received_events","type":"User","site_admin":false},"repo":{"id":33133739,"name":"kubernetes","full_name":"jiangyaoguo/kubernetes","owner":{"login":"jiangyaoguo","id":6777418,"avatar_url":"https://avatars.githubusercontent.com/u/6777418?v=3","gravatar_id":"","url":"https://api.github.com/users/jiangyaoguo","html_url":"https://github.com/jiangyaoguo","followers_url":"https://api.github.com/users/jiangyaoguo/followers","following_url":"https://api.github.com/users/jiangyaoguo/following{/other_user}","gists_url":"https://api.github.com/users/jiangyaoguo/gists{/gist_id}","starred_url":"https://api.github.com/users/jiangyaoguo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jiangyaoguo/subscriptions","organizations_url":"https://api.github.com/users/jiangyaoguo/orgs","repos_url":"https://api.github.com/users/jiangyaoguo/repos","events_url":"https://api.github.com/users/jiangyaoguo/events{/privacy}","received_events_url":"https://api.github.com/users/jiangyaoguo/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jiangyaoguo/kubernetes","description":"Container Cluster Manager from Google","fork":true,"url":"https://api.github.com/repos/jiangyaoguo/kubernetes","forks_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/forks","keys_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/teams","hooks_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/events","assignees_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/tags","blobs_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/languages","stargazers_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/subscription","commits_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/merges","archive_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/downloads","issues_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/jiangyaoguo/kubernetes/releases{/id}","created_at":"2015-03-30T16:10:38Z","updated_at":"2015-04-03T12:00:16Z","pushed_at":"2015-04-03T12:00:16Z","git_url":"git://github.com/jiangyaoguo/kubernetes.git","ssh_url":"git@github.com:jiangyaoguo/kubernetes.git","clone_url":"https://github.com/jiangyaoguo/kubernetes.git","svn_url":"https://github.com/jiangyaoguo/kubernetes","homepage":"http://kubernetes.io","size":39881,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"GoogleCloudPlatform:master","ref":"master","sha":"25724f7e316dc7e6258cfb181507a1dbc9100038","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"repo":{"id":20580498,"name":"kubernetes","full_name":"GoogleCloudPlatform/kubernetes","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GoogleCloudPlatform/kubernetes","description":"Container Cluster Manager from Google","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/releases{/id}","created_at":"2014-06-06T22:56:04Z","updated_at":"2015-04-03T15:51:42Z","pushed_at":"2015-04-03T16:02:41Z","git_url":"git://github.com/GoogleCloudPlatform/kubernetes.git","ssh_url":"git@github.com:GoogleCloudPlatform/kubernetes.git","clone_url":"https://github.com/GoogleCloudPlatform/kubernetes.git","svn_url":"https://github.com/GoogleCloudPlatform/kubernetes","homepage":"http://kubernetes.io","size":128878,"stargazers_count":6875,"watchers_count":6875,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1323,"mirror_url":null,"open_issues_count":845,"forks":1323,"open_issues":845,"watchers":6875,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166"},"html":{"href":"https://github.com/GoogleCloudPlatform/kubernetes/pull/6166"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/6166"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/6166/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/6166/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/statuses/6c58d1cff6a7b638f962b20b9808af376f88c70b"}}}}