{"action":"created","comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/comments/150952300","pull_request_review_id":76581874,"id":150952300,"diff_hunk":"@@ -0,0 +1,83 @@\n+# Copyright 2017 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+# Yaml file to install a DaemonSet that contains a device plugin for\n+# managing nvidia gpu devices. Expected to be deployed in Kubernetes\n+# clusters with nvidia gpu devices. On each node, the DaemonSet detects\n+# whether there are nvidia gpu devices, and if so, sets up the devices\n+# in ready state and report them to Kubelet through the device plugin\n+# interface. The device plugin simply sleeps if there is no nvidia\n+# gpu device on the node.\n+\n+apiVersion: extensions/v1beta1\n+kind: DaemonSet\n+metadata:\n+  name: nvidia-driver-installer\n+  namespace: kube-system\n+spec:\n+  template:\n+    metadata:\n+      labels:\n+        name: nvidia-driver-installer\n+    spec:\n+      affinity:\n+        nodeAffinity:\n+          requiredDuringSchedulingIgnoredDuringExecution:\n+            nodeSelectorTerms:\n+            - matchExpressions:\n+              - key: cloud.google.com/gke-accelerator\n+                operator: Exists\n+      hostNetwork: true\n+      hostPID: true\n+      volumes:\n+      - name: dev\n+        hostPath:\n+          path: /dev\n+      - name: nvidia-overlay\n+        hostPath:\n+          path: /home/kubernetes/bin/nvidia\n+      - name: os-release\n+        hostPath:\n+          path: /etc/os-release\n+      - name: sysrq\n+        hostPath:\n+          path: /proc/sysrq-trigger\n+      initContainers:\n+      - image: \"cos-nvidia-installer:fixed\"\n+        imagePullPolicy: Never\n+        command: [\"/bin/sh\", \"-c\"]\n+        args: [\"usr/bin/nvidia-installer.sh\"]\n+        name: nvidia-driver-installer\n+        resources:\n+          requests:\n+            cpu: 0.15","path":"daemonset-preloaded.yaml","position":64,"original_position":64,"commit_id":"4fd24fa94e5a392d7560dab3571d9af4441cc144","original_commit_id":"4fd24fa94e5a392d7560dab3571d9af4441cc144","user":{"login":"mindprince","id":695290,"avatar_url":"https://avatars2.githubusercontent.com/u/695290?v=4","gravatar_id":"","url":"https://api.github.com/users/mindprince","html_url":"https://github.com/mindprince","followers_url":"https://api.github.com/users/mindprince/followers","following_url":"https://api.github.com/users/mindprince/following{/other_user}","gists_url":"https://api.github.com/users/mindprince/gists{/gist_id}","starred_url":"https://api.github.com/users/mindprince/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mindprince/subscriptions","organizations_url":"https://api.github.com/users/mindprince/orgs","repos_url":"https://api.github.com/users/mindprince/repos","events_url":"https://api.github.com/users/mindprince/events{/privacy}","received_events_url":"https://api.github.com/users/mindprince/received_events","type":"User","site_admin":false},"body":"I am not sure. That would in effect reduce the capacity of all GPU nodes by 2 cores.","created_at":"2017-11-14T20:22:23Z","updated_at":"2017-11-14T20:22:23Z","html_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25#discussion_r150952300","pull_request_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/comments/150952300"},"html":{"href":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25#discussion_r150952300"},"pull_request":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25"}},"in_reply_to_id":150948286},"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25","id":152401204,"html_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25","diff_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25.diff","patch_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/25","number":25,"state":"open","locked":false,"title":"No need to run device-plugin manually anymore.","user":{"login":"mindprince","id":695290,"avatar_url":"https://avatars2.githubusercontent.com/u/695290?v=4","gravatar_id":"","url":"https://api.github.com/users/mindprince","html_url":"https://github.com/mindprince","followers_url":"https://api.github.com/users/mindprince/followers","following_url":"https://api.github.com/users/mindprince/following{/other_user}","gists_url":"https://api.github.com/users/mindprince/gists{/gist_id}","starred_url":"https://api.github.com/users/mindprince/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mindprince/subscriptions","organizations_url":"https://api.github.com/users/mindprince/orgs","repos_url":"https://api.github.com/users/mindprince/repos","events_url":"https://api.github.com/users/mindprince/events{/privacy}","received_events_url":"https://api.github.com/users/mindprince/received_events","type":"User","site_admin":false},"body":"It's an addon in GCP now. The manifest for that is here:\r\nhttps://github.com/kubernetes/kubernetes/blob/master/cluster/addons/device-plugins/nvidia-gpu/daemonset.yaml\r\n\r\nInstead of that a pause container is run, so that the installer can remain an init container.\r\nAlso, added node affinity to only run on nodes that have a label with key 'cloud.google.com/gke-accelerator'.\r\n\r\n---\r\n\r\nThere are three files now:\r\n1) device-plugin-daemonset.yaml\r\n2) daemonset.yaml\r\n3) daemonset-preloaded.yaml\r\n\r\n(1) already existed but its name no longer makes sense. (2) is copy of (1).\r\n(3) is copy of (2) except that the installer image is assumed to be present on\r\nthe node. (1) would be deleted once tests in kubernetes/kubernetes are updated\r\nto point to (2) or (3).","created_at":"2017-11-14T02:55:02Z","updated_at":"2017-11-14T20:22:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6e5e7ba8aaf807515e5d6568e62a902558c887eb","assignee":null,"assignees":[],"requested_reviewers":[{"login":"vishh","id":7063592,"avatar_url":"https://avatars2.githubusercontent.com/u/7063592?v=4","gravatar_id":"","url":"https://api.github.com/users/vishh","html_url":"https://github.com/vishh","followers_url":"https://api.github.com/users/vishh/followers","following_url":"https://api.github.com/users/vishh/following{/other_user}","gists_url":"https://api.github.com/users/vishh/gists{/gist_id}","starred_url":"https://api.github.com/users/vishh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vishh/subscriptions","organizations_url":"https://api.github.com/users/vishh/orgs","repos_url":"https://api.github.com/users/vishh/repos","events_url":"https://api.github.com/users/vishh/events{/privacy}","received_events_url":"https://api.github.com/users/vishh/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/25/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/statuses/4fd24fa94e5a392d7560dab3571d9af4441cc144","head":{"label":"mindprince:device-plugin-is-now-addon","ref":"device-plugin-is-now-addon","sha":"4fd24fa94e5a392d7560dab3571d9af4441cc144","user":{"login":"mindprince","id":695290,"avatar_url":"https://avatars2.githubusercontent.com/u/695290?v=4","gravatar_id":"","url":"https://api.github.com/users/mindprince","html_url":"https://github.com/mindprince","followers_url":"https://api.github.com/users/mindprince/followers","following_url":"https://api.github.com/users/mindprince/following{/other_user}","gists_url":"https://api.github.com/users/mindprince/gists{/gist_id}","starred_url":"https://api.github.com/users/mindprince/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mindprince/subscriptions","organizations_url":"https://api.github.com/users/mindprince/orgs","repos_url":"https://api.github.com/users/mindprince/repos","events_url":"https://api.github.com/users/mindprince/events{/privacy}","received_events_url":"https://api.github.com/users/mindprince/received_events","type":"User","site_admin":false},"repo":{"id":102781143,"name":"container-engine-accelerators","full_name":"mindprince/container-engine-accelerators","owner":{"login":"mindprince","id":695290,"avatar_url":"https://avatars2.githubusercontent.com/u/695290?v=4","gravatar_id":"","url":"https://api.github.com/users/mindprince","html_url":"https://github.com/mindprince","followers_url":"https://api.github.com/users/mindprince/followers","following_url":"https://api.github.com/users/mindprince/following{/other_user}","gists_url":"https://api.github.com/users/mindprince/gists{/gist_id}","starred_url":"https://api.github.com/users/mindprince/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mindprince/subscriptions","organizations_url":"https://api.github.com/users/mindprince/orgs","repos_url":"https://api.github.com/users/mindprince/repos","events_url":"https://api.github.com/users/mindprince/events{/privacy}","received_events_url":"https://api.github.com/users/mindprince/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mindprince/container-engine-accelerators","description":"Collection of tools and examples for managing Accelerated workloads in Container Engine","fork":true,"url":"https://api.github.com/repos/mindprince/container-engine-accelerators","forks_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/forks","keys_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/teams","hooks_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/hooks","issue_events_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/issues/events{/number}","events_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/events","assignees_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/assignees{/user}","branches_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/branches{/branch}","tags_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/tags","blobs_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/git/refs{/sha}","trees_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/statuses/{sha}","languages_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/languages","stargazers_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/stargazers","contributors_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/contributors","subscribers_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/subscribers","subscription_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/subscription","commits_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/commits{/sha}","git_commits_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/git/commits{/sha}","comments_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/comments{/number}","issue_comment_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/issues/comments{/number}","contents_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/contents/{+path}","compare_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/merges","archive_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/downloads","issues_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/issues{/number}","pulls_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/pulls{/number}","milestones_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/milestones{/number}","notifications_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/labels{/name}","releases_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/releases{/id}","deployments_url":"https://api.github.com/repos/mindprince/container-engine-accelerators/deployments","created_at":"2017-09-07T20:10:49Z","updated_at":"2017-09-07T20:10:52Z","pushed_at":"2017-11-14T02:40:50Z","git_url":"git://github.com/mindprince/container-engine-accelerators.git","ssh_url":"git@github.com:mindprince/container-engine-accelerators.git","clone_url":"https://github.com/mindprince/container-engine-accelerators.git","svn_url":"https://github.com/mindprince/container-engine-accelerators","homepage":"","size":23134,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"GoogleCloudPlatform:master","ref":"master","sha":"dc8f2d19dde3ce38b64269e92015308819189762","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars0.githubusercontent.com/u/2810941?v=4","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":101113696,"name":"container-engine-accelerators","full_name":"GoogleCloudPlatform/container-engine-accelerators","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars0.githubusercontent.com/u/2810941?v=4","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/container-engine-accelerators","description":"Collection of tools and examples for managing Accelerated workloads in Container Engine","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/releases{/id}","deployments_url":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/deployments","created_at":"2017-08-22T22:41:30Z","updated_at":"2017-11-14T00:51:06Z","pushed_at":"2017-11-14T02:55:03Z","git_url":"git://github.com/GoogleCloudPlatform/container-engine-accelerators.git","ssh_url":"git@github.com:GoogleCloudPlatform/container-engine-accelerators.git","clone_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators.git","svn_url":"https://github.com/GoogleCloudPlatform/container-engine-accelerators","homepage":"","size":23132,"stargazers_count":14,"watchers_count":14,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":11,"mirror_url":null,"archived":false,"open_issues_count":3,"forks":11,"open_issues":3,"watchers":14,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25"},"html":{"href":"https://github.com/GoogleCloudPlatform/container-engine-accelerators/pull/25"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/25"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/issues/25/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/pulls/25/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/container-engine-accelerators/statuses/4fd24fa94e5a392d7560dab3571d9af4441cc144"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"mindprince"}}