{"action":"created","comment":{"url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/comments/237440476","pull_request_review_id":179736769,"id":237440476,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNzQ0MDQ3Ng==","diff_hunk":"@@ -530,3 +531,14 @@ func GetReleaseScanLog(c *gin.Context) (map[string]bool, bool) {\n \tlog.Debugf(\"ReleaseScanLogReject set: %#v\", releaseScanLogReject)\n \treturn releaseScanLogReject, true\n }\n+\n+// SecurytiScanEnabled checks if security scan is enabled in pipeline\n+func SecurytiScanEnabled(c *gin.Context) {\n+\n+\tif viper.GetBool(\"anchore.enabled\") {\n+\t\tc.Status(http.StatusOK)\n+\t\treturn\n+\t}\n+\tc.Status(http.StatusBadRequest)","path":"api/security.go","position":20,"original_position":20,"commit_id":"262ed9b1dc0fa3d9667db68f5584f2ee9d4d3371","original_commit_id":"262ed9b1dc0fa3d9667db68f5584f2ee9d4d3371","user":{"login":"bonifaido","id":23779,"node_id":"MDQ6VXNlcjIzNzc5","avatar_url":"https://avatars0.githubusercontent.com/u/23779?v=4","gravatar_id":"","url":"https://api.github.com/users/bonifaido","html_url":"https://github.com/bonifaido","followers_url":"https://api.github.com/users/bonifaido/followers","following_url":"https://api.github.com/users/bonifaido/following{/other_user}","gists_url":"https://api.github.com/users/bonifaido/gists{/gist_id}","starred_url":"https://api.github.com/users/bonifaido/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bonifaido/subscriptions","organizations_url":"https://api.github.com/users/bonifaido/orgs","repos_url":"https://api.github.com/users/bonifaido/repos","events_url":"https://api.github.com/users/bonifaido/events{/privacy}","received_events_url":"https://api.github.com/users/bonifaido/received_events","type":"User","site_admin":false},"body":"I would return some other 200 always and the body should contain the boolean I guess, because this is not a client error.","created_at":"2018-11-29T11:01:33Z","updated_at":"2018-11-29T11:01:33Z","html_url":"https://github.com/banzaicloud/pipeline/pull/1472#discussion_r237440476","pull_request_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/comments/237440476"},"html":{"href":"https://github.com/banzaicloud/pipeline/pull/1472#discussion_r237440476"},"pull_request":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472"}}},"pull_request":{"url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472","id":234591748,"node_id":"MDExOlB1bGxSZXF1ZXN0MjM0NTkxNzQ4","html_url":"https://github.com/banzaicloud/pipeline/pull/1472","diff_url":"https://github.com/banzaicloud/pipeline/pull/1472.diff","patch_url":"https://github.com/banzaicloud/pipeline/pull/1472.patch","issue_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/1472","number":1472,"state":"open","locked":false,"title":"Is security scan enabled globally API","user":{"login":"pbalogh-sa","id":13311234,"node_id":"MDQ6VXNlcjEzMzExMjM0","avatar_url":"https://avatars3.githubusercontent.com/u/13311234?v=4","gravatar_id":"","url":"https://api.github.com/users/pbalogh-sa","html_url":"https://github.com/pbalogh-sa","followers_url":"https://api.github.com/users/pbalogh-sa/followers","following_url":"https://api.github.com/users/pbalogh-sa/following{/other_user}","gists_url":"https://api.github.com/users/pbalogh-sa/gists{/gist_id}","starred_url":"https://api.github.com/users/pbalogh-sa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pbalogh-sa/subscriptions","organizations_url":"https://api.github.com/users/pbalogh-sa/orgs","repos_url":"https://api.github.com/users/pbalogh-sa/repos","events_url":"https://api.github.com/users/pbalogh-sa/events{/privacy}","received_events_url":"https://api.github.com/users/pbalogh-sa/received_events","type":"User","site_admin":false},"body":"Add API endpoint to check whether security scan is enabled in ENV.\r\nfixes: #1428 ","created_at":"2018-11-29T10:54:33Z","updated_at":"2018-11-29T11:01:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3e25ef7029d8528d3661d293380dd5ed2bb5794d","assignee":null,"assignees":[],"requested_reviewers":[{"login":"sagikazarmark","id":1226384,"node_id":"MDQ6VXNlcjEyMjYzODQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1226384?v=4","gravatar_id":"","url":"https://api.github.com/users/sagikazarmark","html_url":"https://github.com/sagikazarmark","followers_url":"https://api.github.com/users/sagikazarmark/followers","following_url":"https://api.github.com/users/sagikazarmark/following{/other_user}","gists_url":"https://api.github.com/users/sagikazarmark/gists{/gist_id}","starred_url":"https://api.github.com/users/sagikazarmark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sagikazarmark/subscriptions","organizations_url":"https://api.github.com/users/sagikazarmark/orgs","repos_url":"https://api.github.com/users/sagikazarmark/repos","events_url":"https://api.github.com/users/sagikazarmark/events{/privacy}","received_events_url":"https://api.github.com/users/sagikazarmark/received_events","type":"User","site_admin":false},{"login":"stoader","id":6655123,"node_id":"MDQ6VXNlcjY2NTUxMjM=","avatar_url":"https://avatars3.githubusercontent.com/u/6655123?v=4","gravatar_id":"","url":"https://api.github.com/users/stoader","html_url":"https://github.com/stoader","followers_url":"https://api.github.com/users/stoader/followers","following_url":"https://api.github.com/users/stoader/following{/other_user}","gists_url":"https://api.github.com/users/stoader/gists{/gist_id}","starred_url":"https://api.github.com/users/stoader/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stoader/subscriptions","organizations_url":"https://api.github.com/users/stoader/orgs","repos_url":"https://api.github.com/users/stoader/repos","events_url":"https://api.github.com/users/stoader/events{/privacy}","received_events_url":"https://api.github.com/users/stoader/received_events","type":"User","site_admin":false},{"login":"colin014","id":6968817,"node_id":"MDQ6VXNlcjY5Njg4MTc=","avatar_url":"https://avatars3.githubusercontent.com/u/6968817?v=4","gravatar_id":"","url":"https://api.github.com/users/colin014","html_url":"https://github.com/colin014","followers_url":"https://api.github.com/users/colin014/followers","following_url":"https://api.github.com/users/colin014/following{/other_user}","gists_url":"https://api.github.com/users/colin014/gists{/gist_id}","starred_url":"https://api.github.com/users/colin014/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/colin014/subscriptions","organizations_url":"https://api.github.com/users/colin014/orgs","repos_url":"https://api.github.com/users/colin014/repos","events_url":"https://api.github.com/users/colin014/events{/privacy}","received_events_url":"https://api.github.com/users/colin014/received_events","type":"User","site_admin":false},{"login":"baluchicken","id":14196407,"node_id":"MDQ6VXNlcjE0MTk2NDA3","avatar_url":"https://avatars0.githubusercontent.com/u/14196407?v=4","gravatar_id":"","url":"https://api.github.com/users/baluchicken","html_url":"https://github.com/baluchicken","followers_url":"https://api.github.com/users/baluchicken/followers","following_url":"https://api.github.com/users/baluchicken/following{/other_user}","gists_url":"https://api.github.com/users/baluchicken/gists{/gist_id}","starred_url":"https://api.github.com/users/baluchicken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baluchicken/subscriptions","organizations_url":"https://api.github.com/users/baluchicken/orgs","repos_url":"https://api.github.com/users/baluchicken/repos","events_url":"https://api.github.com/users/baluchicken/events{/privacy}","received_events_url":"https://api.github.com/users/baluchicken/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472/commits","review_comments_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472/comments","review_comment_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls/comments{/number}","comments_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/1472/comments","statuses_url":"https://api.github.com/repos/banzaicloud/pipeline/statuses/262ed9b1dc0fa3d9667db68f5584f2ee9d4d3371","head":{"label":"banzaicloud:is-enabled-anchore","ref":"is-enabled-anchore","sha":"262ed9b1dc0fa3d9667db68f5584f2ee9d4d3371","user":{"login":"banzaicloud","id":32848483,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyODQ4NDgz","avatar_url":"https://avatars2.githubusercontent.com/u/32848483?v=4","gravatar_id":"","url":"https://api.github.com/users/banzaicloud","html_url":"https://github.com/banzaicloud","followers_url":"https://api.github.com/users/banzaicloud/followers","following_url":"https://api.github.com/users/banzaicloud/following{/other_user}","gists_url":"https://api.github.com/users/banzaicloud/gists{/gist_id}","starred_url":"https://api.github.com/users/banzaicloud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banzaicloud/subscriptions","organizations_url":"https://api.github.com/users/banzaicloud/orgs","repos_url":"https://api.github.com/users/banzaicloud/repos","events_url":"https://api.github.com/users/banzaicloud/events{/privacy}","received_events_url":"https://api.github.com/users/banzaicloud/received_events","type":"Organization","site_admin":false},"repo":{"id":108758373,"node_id":"MDEwOlJlcG9zaXRvcnkxMDg3NTgzNzM=","name":"pipeline","full_name":"banzaicloud/pipeline","private":false,"owner":{"login":"banzaicloud","id":32848483,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyODQ4NDgz","avatar_url":"https://avatars2.githubusercontent.com/u/32848483?v=4","gravatar_id":"","url":"https://api.github.com/users/banzaicloud","html_url":"https://github.com/banzaicloud","followers_url":"https://api.github.com/users/banzaicloud/followers","following_url":"https://api.github.com/users/banzaicloud/following{/other_user}","gists_url":"https://api.github.com/users/banzaicloud/gists{/gist_id}","starred_url":"https://api.github.com/users/banzaicloud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banzaicloud/subscriptions","organizations_url":"https://api.github.com/users/banzaicloud/orgs","repos_url":"https://api.github.com/users/banzaicloud/repos","events_url":"https://api.github.com/users/banzaicloud/events{/privacy}","received_events_url":"https://api.github.com/users/banzaicloud/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/banzaicloud/pipeline","description":"Pipeline enables developers to go from commit to scale in minutes by turning Kubernetes into a feature rich application platform integrating CI/CD, centralized logging, monitoring, enterprise-grade security and autoscaling.","fork":false,"url":"https://api.github.com/repos/banzaicloud/pipeline","forks_url":"https://api.github.com/repos/banzaicloud/pipeline/forks","keys_url":"https://api.github.com/repos/banzaicloud/pipeline/keys{/key_id}","collaborators_url":"https://api.github.com/repos/banzaicloud/pipeline/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/banzaicloud/pipeline/teams","hooks_url":"https://api.github.com/repos/banzaicloud/pipeline/hooks","issue_events_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/events{/number}","events_url":"https://api.github.com/repos/banzaicloud/pipeline/events","assignees_url":"https://api.github.com/repos/banzaicloud/pipeline/assignees{/user}","branches_url":"https://api.github.com/repos/banzaicloud/pipeline/branches{/branch}","tags_url":"https://api.github.com/repos/banzaicloud/pipeline/tags","blobs_url":"https://api.github.com/repos/banzaicloud/pipeline/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/banzaicloud/pipeline/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/banzaicloud/pipeline/git/refs{/sha}","trees_url":"https://api.github.com/repos/banzaicloud/pipeline/git/trees{/sha}","statuses_url":"https://api.github.com/repos/banzaicloud/pipeline/statuses/{sha}","languages_url":"https://api.github.com/repos/banzaicloud/pipeline/languages","stargazers_url":"https://api.github.com/repos/banzaicloud/pipeline/stargazers","contributors_url":"https://api.github.com/repos/banzaicloud/pipeline/contributors","subscribers_url":"https://api.github.com/repos/banzaicloud/pipeline/subscribers","subscription_url":"https://api.github.com/repos/banzaicloud/pipeline/subscription","commits_url":"https://api.github.com/repos/banzaicloud/pipeline/commits{/sha}","git_commits_url":"https://api.github.com/repos/banzaicloud/pipeline/git/commits{/sha}","comments_url":"https://api.github.com/repos/banzaicloud/pipeline/comments{/number}","issue_comment_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/comments{/number}","contents_url":"https://api.github.com/repos/banzaicloud/pipeline/contents/{+path}","compare_url":"https://api.github.com/repos/banzaicloud/pipeline/compare/{base}...{head}","merges_url":"https://api.github.com/repos/banzaicloud/pipeline/merges","archive_url":"https://api.github.com/repos/banzaicloud/pipeline/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/banzaicloud/pipeline/downloads","issues_url":"https://api.github.com/repos/banzaicloud/pipeline/issues{/number}","pulls_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls{/number}","milestones_url":"https://api.github.com/repos/banzaicloud/pipeline/milestones{/number}","notifications_url":"https://api.github.com/repos/banzaicloud/pipeline/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/banzaicloud/pipeline/labels{/name}","releases_url":"https://api.github.com/repos/banzaicloud/pipeline/releases{/id}","deployments_url":"https://api.github.com/repos/banzaicloud/pipeline/deployments","created_at":"2017-10-29T18:07:56Z","updated_at":"2018-11-29T10:13:43Z","pushed_at":"2018-11-29T10:55:45Z","git_url":"git://github.com/banzaicloud/pipeline.git","ssh_url":"git@github.com:banzaicloud/pipeline.git","clone_url":"https://github.com/banzaicloud/pipeline.git","svn_url":"https://github.com/banzaicloud/pipeline","homepage":"","size":86132,"stargazers_count":752,"watchers_count":752,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":70,"mirror_url":null,"archived":false,"open_issues_count":66,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":70,"open_issues":66,"watchers":752,"default_branch":"master"}},"base":{"label":"banzaicloud:master","ref":"master","sha":"8cb03c63a0cbe6432b18a3c8c4039a8a95bed6ba","user":{"login":"banzaicloud","id":32848483,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyODQ4NDgz","avatar_url":"https://avatars2.githubusercontent.com/u/32848483?v=4","gravatar_id":"","url":"https://api.github.com/users/banzaicloud","html_url":"https://github.com/banzaicloud","followers_url":"https://api.github.com/users/banzaicloud/followers","following_url":"https://api.github.com/users/banzaicloud/following{/other_user}","gists_url":"https://api.github.com/users/banzaicloud/gists{/gist_id}","starred_url":"https://api.github.com/users/banzaicloud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banzaicloud/subscriptions","organizations_url":"https://api.github.com/users/banzaicloud/orgs","repos_url":"https://api.github.com/users/banzaicloud/repos","events_url":"https://api.github.com/users/banzaicloud/events{/privacy}","received_events_url":"https://api.github.com/users/banzaicloud/received_events","type":"Organization","site_admin":false},"repo":{"id":108758373,"node_id":"MDEwOlJlcG9zaXRvcnkxMDg3NTgzNzM=","name":"pipeline","full_name":"banzaicloud/pipeline","private":false,"owner":{"login":"banzaicloud","id":32848483,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyODQ4NDgz","avatar_url":"https://avatars2.githubusercontent.com/u/32848483?v=4","gravatar_id":"","url":"https://api.github.com/users/banzaicloud","html_url":"https://github.com/banzaicloud","followers_url":"https://api.github.com/users/banzaicloud/followers","following_url":"https://api.github.com/users/banzaicloud/following{/other_user}","gists_url":"https://api.github.com/users/banzaicloud/gists{/gist_id}","starred_url":"https://api.github.com/users/banzaicloud/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banzaicloud/subscriptions","organizations_url":"https://api.github.com/users/banzaicloud/orgs","repos_url":"https://api.github.com/users/banzaicloud/repos","events_url":"https://api.github.com/users/banzaicloud/events{/privacy}","received_events_url":"https://api.github.com/users/banzaicloud/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/banzaicloud/pipeline","description":"Pipeline enables developers to go from commit to scale in minutes by turning Kubernetes into a feature rich application platform integrating CI/CD, centralized logging, monitoring, enterprise-grade security and autoscaling.","fork":false,"url":"https://api.github.com/repos/banzaicloud/pipeline","forks_url":"https://api.github.com/repos/banzaicloud/pipeline/forks","keys_url":"https://api.github.com/repos/banzaicloud/pipeline/keys{/key_id}","collaborators_url":"https://api.github.com/repos/banzaicloud/pipeline/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/banzaicloud/pipeline/teams","hooks_url":"https://api.github.com/repos/banzaicloud/pipeline/hooks","issue_events_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/events{/number}","events_url":"https://api.github.com/repos/banzaicloud/pipeline/events","assignees_url":"https://api.github.com/repos/banzaicloud/pipeline/assignees{/user}","branches_url":"https://api.github.com/repos/banzaicloud/pipeline/branches{/branch}","tags_url":"https://api.github.com/repos/banzaicloud/pipeline/tags","blobs_url":"https://api.github.com/repos/banzaicloud/pipeline/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/banzaicloud/pipeline/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/banzaicloud/pipeline/git/refs{/sha}","trees_url":"https://api.github.com/repos/banzaicloud/pipeline/git/trees{/sha}","statuses_url":"https://api.github.com/repos/banzaicloud/pipeline/statuses/{sha}","languages_url":"https://api.github.com/repos/banzaicloud/pipeline/languages","stargazers_url":"https://api.github.com/repos/banzaicloud/pipeline/stargazers","contributors_url":"https://api.github.com/repos/banzaicloud/pipeline/contributors","subscribers_url":"https://api.github.com/repos/banzaicloud/pipeline/subscribers","subscription_url":"https://api.github.com/repos/banzaicloud/pipeline/subscription","commits_url":"https://api.github.com/repos/banzaicloud/pipeline/commits{/sha}","git_commits_url":"https://api.github.com/repos/banzaicloud/pipeline/git/commits{/sha}","comments_url":"https://api.github.com/repos/banzaicloud/pipeline/comments{/number}","issue_comment_url":"https://api.github.com/repos/banzaicloud/pipeline/issues/comments{/number}","contents_url":"https://api.github.com/repos/banzaicloud/pipeline/contents/{+path}","compare_url":"https://api.github.com/repos/banzaicloud/pipeline/compare/{base}...{head}","merges_url":"https://api.github.com/repos/banzaicloud/pipeline/merges","archive_url":"https://api.github.com/repos/banzaicloud/pipeline/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/banzaicloud/pipeline/downloads","issues_url":"https://api.github.com/repos/banzaicloud/pipeline/issues{/number}","pulls_url":"https://api.github.com/repos/banzaicloud/pipeline/pulls{/number}","milestones_url":"https://api.github.com/repos/banzaicloud/pipeline/milestones{/number}","notifications_url":"https://api.github.com/repos/banzaicloud/pipeline/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/banzaicloud/pipeline/labels{/name}","releases_url":"https://api.github.com/repos/banzaicloud/pipeline/releases{/id}","deployments_url":"https://api.github.com/repos/banzaicloud/pipeline/deployments","created_at":"2017-10-29T18:07:56Z","updated_at":"2018-11-29T10:13:43Z","pushed_at":"2018-11-29T10:55:45Z","git_url":"git://github.com/banzaicloud/pipeline.git","ssh_url":"git@github.com:banzaicloud/pipeline.git","clone_url":"https://github.com/banzaicloud/pipeline.git","svn_url":"https://github.com/banzaicloud/pipeline","homepage":"","size":86132,"stargazers_count":752,"watchers_count":752,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":70,"mirror_url":null,"archived":false,"open_issues_count":66,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":70,"open_issues":66,"watchers":752,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472"},"html":{"href":"https://github.com/banzaicloud/pipeline/pull/1472"},"issue":{"href":"https://api.github.com/repos/banzaicloud/pipeline/issues/1472"},"comments":{"href":"https://api.github.com/repos/banzaicloud/pipeline/issues/1472/comments"},"review_comments":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472/comments"},"review_comment":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/banzaicloud/pipeline/pulls/1472/commits"},"statuses":{"href":"https://api.github.com/repos/banzaicloud/pipeline/statuses/262ed9b1dc0fa3d9667db68f5584f2ee9d4d3371"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"bonifaido"}}