[K/N][perf] Use properties file to get TeamCity URL

This commit is contained in:
Pavel Punegov
2022-07-26 13:50:17 +03:00
committed by Space
parent 911512ba96
commit a961a93da7
+8 -1
View File
@@ -312,10 +312,17 @@ subprojects.each {
}
task teamCityStat(type:Exec) {
def teamcityUrl = ""
def teamcityConfig = System.getenv("TEAMCITY_BUILD_PROPERTIES_FILE")
if (teamcityConfig) {
def buildProperties = new Properties()
buildProperties.load(new FileInputStream(teamcityConfig))
teamcityUrl = buildProperties.getProperty("teamcity.serverUrl")
}
def analyzer = findAnalyzerBinary()
commandLine analyzer, "-r", "teamcity",
"--artifactory-url", "https://repo.labs.intellij.net/kotlin-native-benchmarks",
"--teamcity-url", "http://buildserver.labs.intellij.net",
"--teamcity-url", teamcityUrl,
"--server-url", findProperty("kotlin.native.performance.server.url")?.toString() ?: "http://localhost:3000",
"${buildDir.absolutePath}/${nativeJson}"
}