Add build operating system as build scan tag (#45558)

This commit is contained in:
Mark Vieira 2019-08-14 13:16:20 -07:00
parent caa2a7738f
commit 285f011bbb
No known key found for this signature in database
GPG Key ID: CA947EF7E6D4B105
1 changed files with 3 additions and 0 deletions

View File

@ -1,8 +1,11 @@
import nebula.plugin.info.scm.ScmInfoExtension
import org.elasticsearch.gradle.OS
buildScan {
def jenkinsUrl = System.getenv('JENKINS_URL') ? new URL(System.getenv('JENKINS_URL')) : null
tag OS.current().name()
// Accept Gradle ToS when project property org.elasticsearch.acceptScanTOS=true or this is an Elastic CI build
if (jenkinsUrl?.host?.endsWith('elastic.co') || Boolean.valueOf(project.findProperty('org.elasticsearch.acceptScanTOS') ?: "false")) {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'