{"action":"created","comment":{"url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/comments/52190247","id":52190247,"diff_hunk":"@@ -91,8 +97,17 @@ class DeployKubernetesAtomicOperationSpec extends Specification {\n     servicePortMock = Mock(ServicePort)\n     metadataMock = Mock(ObjectMeta)\n     intOrStringMock = Mock(IntOrString)\n+    accountCredentialsRepositoryMock = Mock(AccountCredentialsRepository)\n+\n+    DOCKER_REGISTRY_ACCOUNTS.forEach({ account ->","path":"clouddriver-kubernetes/src/test/groovy/com/netflix/spinnaker/clouddriver/kubernetes/deploy/ops/DeployKubernetesAtomicOperationSpec.groovy","position":58,"original_position":58,"commit_id":"7aee9afe11ae3db7f7e4e929be434d8357407c88","original_commit_id":"7aee9afe11ae3db7f7e4e929be434d8357407c88","user":{"login":"duftler","id":8437718,"avatar_url":"https://avatars.githubusercontent.com/u/8437718?v=3","gravatar_id":"","url":"https://api.github.com/users/duftler","html_url":"https://github.com/duftler","followers_url":"https://api.github.com/users/duftler/followers","following_url":"https://api.github.com/users/duftler/following{/other_user}","gists_url":"https://api.github.com/users/duftler/gists{/gist_id}","starred_url":"https://api.github.com/users/duftler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duftler/subscriptions","organizations_url":"https://api.github.com/users/duftler/orgs","repos_url":"https://api.github.com/users/duftler/repos","events_url":"https://api.github.com/users/duftler/events{/privacy}","received_events_url":"https://api.github.com/users/duftler/received_events","type":"User","site_admin":false},"body":"Are the enclosing parens needed here?","created_at":"2016-02-08T16:26:39Z","updated_at":"2016-02-08T16:26:39Z","html_url":"https://github.com/spinnaker/clouddriver/pull/285#discussion_r52190247","pull_request_url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285","_links":{"self":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/comments/52190247"},"html":{"href":"https://github.com/spinnaker/clouddriver/pull/285#discussion_r52190247"},"pull_request":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285"}}},"pull_request":{"url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285","id":58560740,"html_url":"https://github.com/spinnaker/clouddriver/pull/285","diff_url":"https://github.com/spinnaker/clouddriver/pull/285.diff","patch_url":"https://github.com/spinnaker/clouddriver/pull/285.patch","issue_url":"https://api.github.com/repos/spinnaker/clouddriver/issues/285","number":285,"state":"open","locked":false,"title":"provider/kubernetes: Register docker registry credentials.","user":{"login":"lwander","id":4874941,"avatar_url":"https://avatars.githubusercontent.com/u/4874941?v=3","gravatar_id":"","url":"https://api.github.com/users/lwander","html_url":"https://github.com/lwander","followers_url":"https://api.github.com/users/lwander/followers","following_url":"https://api.github.com/users/lwander/following{/other_user}","gists_url":"https://api.github.com/users/lwander/gists{/gist_id}","starred_url":"https://api.github.com/users/lwander/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lwander/subscriptions","organizations_url":"https://api.github.com/users/lwander/orgs","repos_url":"https://api.github.com/users/lwander/repos","events_url":"https://api.github.com/users/lwander/events{/privacy}","received_events_url":"https://api.github.com/users/lwander/received_events","type":"User","site_admin":false},"body":"This PR achieves 2 things.\r\n\r\n1. The Kubernetes user can define a list of docker registry accounts whose credentials and endpoint will be registered with as a secret with the Kubernetes master. You can read more about how this works [here](http://kubernetes.io/v1.0/docs/user-guide/images.html). The user can also provide an optional list of namespaces (if omitted, every namespace is used) that this registry can be used to deploy images to. The motivation here is to allow users to configure repositories with images specifically for test, prod, staging, etc, if they want to.\r\n\r\n2. While writing the mock tests, I was frustrated with the fact that `KubernetesUtil` was non-static, and had a subset of kubernetes API functionality built in. I took this functionality out, made the remainder static, and placed it into `KubernetesApiAdaptor`. I will now do all API calls through this class. If we need to plug in a separate Kubernetes API it will be easy to abstract and then subclass `KubernetesApiAdaptor`.","created_at":"2016-02-07T23:12:23Z","updated_at":"2016-02-08T16:26:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d710244a85ea80aae4b2969c52213e65b28b8f73","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285/commits","review_comments_url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285/comments","review_comment_url":"https://api.github.com/repos/spinnaker/clouddriver/pulls/comments{/number}","comments_url":"https://api.github.com/repos/spinnaker/clouddriver/issues/285/comments","statuses_url":"https://api.github.com/repos/spinnaker/clouddriver/statuses/7aee9afe11ae3db7f7e4e929be434d8357407c88","head":{"label":"lwander:kubernetes-registry-secret","ref":"kubernetes-registry-secret","sha":"7aee9afe11ae3db7f7e4e929be434d8357407c88","user":{"login":"lwander","id":4874941,"avatar_url":"https://avatars.githubusercontent.com/u/4874941?v=3","gravatar_id":"","url":"https://api.github.com/users/lwander","html_url":"https://github.com/lwander","followers_url":"https://api.github.com/users/lwander/followers","following_url":"https://api.github.com/users/lwander/following{/other_user}","gists_url":"https://api.github.com/users/lwander/gists{/gist_id}","starred_url":"https://api.github.com/users/lwander/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lwander/subscriptions","organizations_url":"https://api.github.com/users/lwander/orgs","repos_url":"https://api.github.com/users/lwander/repos","events_url":"https://api.github.com/users/lwander/events{/privacy}","received_events_url":"https://api.github.com/users/lwander/received_events","type":"User","site_admin":false},"repo":{"id":47214651,"name":"clouddriver","full_name":"lwander/clouddriver","owner":{"login":"lwander","id":4874941,"avatar_url":"https://avatars.githubusercontent.com/u/4874941?v=3","gravatar_id":"","url":"https://api.github.com/users/lwander","html_url":"https://github.com/lwander","followers_url":"https://api.github.com/users/lwander/followers","following_url":"https://api.github.com/users/lwander/following{/other_user}","gists_url":"https://api.github.com/users/lwander/gists{/gist_id}","starred_url":"https://api.github.com/users/lwander/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lwander/subscriptions","organizations_url":"https://api.github.com/users/lwander/orgs","repos_url":"https://api.github.com/users/lwander/repos","events_url":"https://api.github.com/users/lwander/events{/privacy}","received_events_url":"https://api.github.com/users/lwander/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lwander/clouddriver","description":"read and write operations across cloud providers","fork":true,"url":"https://api.github.com/repos/lwander/clouddriver","forks_url":"https://api.github.com/repos/lwander/clouddriver/forks","keys_url":"https://api.github.com/repos/lwander/clouddriver/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lwander/clouddriver/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lwander/clouddriver/teams","hooks_url":"https://api.github.com/repos/lwander/clouddriver/hooks","issue_events_url":"https://api.github.com/repos/lwander/clouddriver/issues/events{/number}","events_url":"https://api.github.com/repos/lwander/clouddriver/events","assignees_url":"https://api.github.com/repos/lwander/clouddriver/assignees{/user}","branches_url":"https://api.github.com/repos/lwander/clouddriver/branches{/branch}","tags_url":"https://api.github.com/repos/lwander/clouddriver/tags","blobs_url":"https://api.github.com/repos/lwander/clouddriver/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lwander/clouddriver/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lwander/clouddriver/git/refs{/sha}","trees_url":"https://api.github.com/repos/lwander/clouddriver/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lwander/clouddriver/statuses/{sha}","languages_url":"https://api.github.com/repos/lwander/clouddriver/languages","stargazers_url":"https://api.github.com/repos/lwander/clouddriver/stargazers","contributors_url":"https://api.github.com/repos/lwander/clouddriver/contributors","subscribers_url":"https://api.github.com/repos/lwander/clouddriver/subscribers","subscription_url":"https://api.github.com/repos/lwander/clouddriver/subscription","commits_url":"https://api.github.com/repos/lwander/clouddriver/commits{/sha}","git_commits_url":"https://api.github.com/repos/lwander/clouddriver/git/commits{/sha}","comments_url":"https://api.github.com/repos/lwander/clouddriver/comments{/number}","issue_comment_url":"https://api.github.com/repos/lwander/clouddriver/issues/comments{/number}","contents_url":"https://api.github.com/repos/lwander/clouddriver/contents/{+path}","compare_url":"https://api.github.com/repos/lwander/clouddriver/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lwander/clouddriver/merges","archive_url":"https://api.github.com/repos/lwander/clouddriver/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lwander/clouddriver/downloads","issues_url":"https://api.github.com/repos/lwander/clouddriver/issues{/number}","pulls_url":"https://api.github.com/repos/lwander/clouddriver/pulls{/number}","milestones_url":"https://api.github.com/repos/lwander/clouddriver/milestones{/number}","notifications_url":"https://api.github.com/repos/lwander/clouddriver/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lwander/clouddriver/labels{/name}","releases_url":"https://api.github.com/repos/lwander/clouddriver/releases{/id}","deployments_url":"https://api.github.com/repos/lwander/clouddriver/deployments","created_at":"2015-12-01T20:13:06Z","updated_at":"2016-01-19T21:43:58Z","pushed_at":"2016-02-07T23:12:15Z","git_url":"git://github.com/lwander/clouddriver.git","ssh_url":"git@github.com:lwander/clouddriver.git","clone_url":"https://github.com/lwander/clouddriver.git","svn_url":"https://github.com/lwander/clouddriver","homepage":null,"size":24212,"stargazers_count":0,"watchers_count":0,"language":"Groovy","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"spinnaker:master","ref":"master","sha":"b94e0c3ca0d385cbb884c4816b1d903cc6134f3c","user":{"login":"spinnaker","id":7634182,"avatar_url":"https://avatars.githubusercontent.com/u/7634182?v=3","gravatar_id":"","url":"https://api.github.com/users/spinnaker","html_url":"https://github.com/spinnaker","followers_url":"https://api.github.com/users/spinnaker/followers","following_url":"https://api.github.com/users/spinnaker/following{/other_user}","gists_url":"https://api.github.com/users/spinnaker/gists{/gist_id}","starred_url":"https://api.github.com/users/spinnaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/spinnaker/subscriptions","organizations_url":"https://api.github.com/users/spinnaker/orgs","repos_url":"https://api.github.com/users/spinnaker/repos","events_url":"https://api.github.com/users/spinnaker/events{/privacy}","received_events_url":"https://api.github.com/users/spinnaker/received_events","type":"Organization","site_admin":false},"repo":{"id":37556951,"name":"clouddriver","full_name":"spinnaker/clouddriver","owner":{"login":"spinnaker","id":7634182,"avatar_url":"https://avatars.githubusercontent.com/u/7634182?v=3","gravatar_id":"","url":"https://api.github.com/users/spinnaker","html_url":"https://github.com/spinnaker","followers_url":"https://api.github.com/users/spinnaker/followers","following_url":"https://api.github.com/users/spinnaker/following{/other_user}","gists_url":"https://api.github.com/users/spinnaker/gists{/gist_id}","starred_url":"https://api.github.com/users/spinnaker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/spinnaker/subscriptions","organizations_url":"https://api.github.com/users/spinnaker/orgs","repos_url":"https://api.github.com/users/spinnaker/repos","events_url":"https://api.github.com/users/spinnaker/events{/privacy}","received_events_url":"https://api.github.com/users/spinnaker/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/spinnaker/clouddriver","description":"read and write operations across cloud providers","fork":false,"url":"https://api.github.com/repos/spinnaker/clouddriver","forks_url":"https://api.github.com/repos/spinnaker/clouddriver/forks","keys_url":"https://api.github.com/repos/spinnaker/clouddriver/keys{/key_id}","collaborators_url":"https://api.github.com/repos/spinnaker/clouddriver/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/spinnaker/clouddriver/teams","hooks_url":"https://api.github.com/repos/spinnaker/clouddriver/hooks","issue_events_url":"https://api.github.com/repos/spinnaker/clouddriver/issues/events{/number}","events_url":"https://api.github.com/repos/spinnaker/clouddriver/events","assignees_url":"https://api.github.com/repos/spinnaker/clouddriver/assignees{/user}","branches_url":"https://api.github.com/repos/spinnaker/clouddriver/branches{/branch}","tags_url":"https://api.github.com/repos/spinnaker/clouddriver/tags","blobs_url":"https://api.github.com/repos/spinnaker/clouddriver/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/spinnaker/clouddriver/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/spinnaker/clouddriver/git/refs{/sha}","trees_url":"https://api.github.com/repos/spinnaker/clouddriver/git/trees{/sha}","statuses_url":"https://api.github.com/repos/spinnaker/clouddriver/statuses/{sha}","languages_url":"https://api.github.com/repos/spinnaker/clouddriver/languages","stargazers_url":"https://api.github.com/repos/spinnaker/clouddriver/stargazers","contributors_url":"https://api.github.com/repos/spinnaker/clouddriver/contributors","subscribers_url":"https://api.github.com/repos/spinnaker/clouddriver/subscribers","subscription_url":"https://api.github.com/repos/spinnaker/clouddriver/subscription","commits_url":"https://api.github.com/repos/spinnaker/clouddriver/commits{/sha}","git_commits_url":"https://api.github.com/repos/spinnaker/clouddriver/git/commits{/sha}","comments_url":"https://api.github.com/repos/spinnaker/clouddriver/comments{/number}","issue_comment_url":"https://api.github.com/repos/spinnaker/clouddriver/issues/comments{/number}","contents_url":"https://api.github.com/repos/spinnaker/clouddriver/contents/{+path}","compare_url":"https://api.github.com/repos/spinnaker/clouddriver/compare/{base}...{head}","merges_url":"https://api.github.com/repos/spinnaker/clouddriver/merges","archive_url":"https://api.github.com/repos/spinnaker/clouddriver/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/spinnaker/clouddriver/downloads","issues_url":"https://api.github.com/repos/spinnaker/clouddriver/issues{/number}","pulls_url":"https://api.github.com/repos/spinnaker/clouddriver/pulls{/number}","milestones_url":"https://api.github.com/repos/spinnaker/clouddriver/milestones{/number}","notifications_url":"https://api.github.com/repos/spinnaker/clouddriver/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/spinnaker/clouddriver/labels{/name}","releases_url":"https://api.github.com/repos/spinnaker/clouddriver/releases{/id}","deployments_url":"https://api.github.com/repos/spinnaker/clouddriver/deployments","created_at":"2015-06-16T21:26:02Z","updated_at":"2016-02-05T04:17:58Z","pushed_at":"2016-02-07T23:12:23Z","git_url":"git://github.com/spinnaker/clouddriver.git","ssh_url":"git@github.com:spinnaker/clouddriver.git","clone_url":"https://github.com/spinnaker/clouddriver.git","svn_url":"https://github.com/spinnaker/clouddriver","homepage":null,"size":26153,"stargazers_count":29,"watchers_count":29,"language":"Groovy","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":37,"mirror_url":null,"open_issues_count":9,"forks":37,"open_issues":9,"watchers":29,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285"},"html":{"href":"https://github.com/spinnaker/clouddriver/pull/285"},"issue":{"href":"https://api.github.com/repos/spinnaker/clouddriver/issues/285"},"comments":{"href":"https://api.github.com/repos/spinnaker/clouddriver/issues/285/comments"},"review_comments":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285/comments"},"review_comment":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/spinnaker/clouddriver/pulls/285/commits"},"statuses":{"href":"https://api.github.com/repos/spinnaker/clouddriver/statuses/7aee9afe11ae3db7f7e4e929be434d8357407c88"}}}}