【发布时间】:2020-04-21 03:55:33
【问题描述】:
您好,我正在使用带有声纳的 aws 代码构建来进行 bitbucket 拉取请求装饰......但我没有收到任何关于拉取请求的 cmets....
aws 代码构建日志....
[sonar4bitbucket] No open pull requests with source branch '' found. No analysis will be performed. ....
这是我的 aws 代码构建命令 ....
sonar-scanner -Dsonar.branch=$GIT_BRANCH -Dsonar.bitbucket.branchName=$GIT_BRANCH -Dsonar.analysis.mode=issues -Dsonar.bitbucket.oauthClientSecret=secret -Dsonar.bitbucket.oauthClientKey=key -Dsonar.bitbucket.minSeverity=INFO -Dsonar.host.url=my server-url -Dsonar.bitbucket.teamName=teamname -Dsonar.bitbucket.repoSlug=myreponame -Dsonar.bitbucket.accountName=my-account-name -Dsonar.bitbucket.approvalFeatureEnabled=false -Dsonar.bitbucket.buildStatusEnabled=true
我认为问题在于这两个属性,即-Dsonar.branch=$GIT_BRANCH -Dsonar.bitbucket.branchName=$GIT_BRANCH,但我不知道如何从 aws 代码构建环境变量中获取这些属性的值
(https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-env-vars.html)
【问题讨论】:
标签: amazon-web-services bitbucket sonarqube-scan aws-codebuild