我有以下基本发布代码。
buildscript {
repositories {
maven {
url "${artifactory_contextUrl}/plugins-release"
credentials {
username = "${artifactory_user}"
password = "${artifactory_password}"
}
}
}
dependencies {
classpath "org.jfrog.buildinfo:build-info-extractor-gradle:4+"
}
}
allprojects {
apply plugin: "com.jfrog.artifactory"
apply plugin: 'maven'
apply plugin: 'maven-publish'
}
artifactory {
contextUrl = "${artifactory_contextUrl}"
publish {
repository {
repoKey = "${publish_repository_key}"
username = "${artifactory_user}"
password = "${artifactory_password}"
maven = true
}
}
resolve {
repository {
repoKey = "${resolve_repository_key}"
username = "${artifactory_user}"
password = "${artifactory_password}"
maven = true
}
}
clientConfig.timeout = 10
}
publishing {
publications {
mavenJava(MavenPublication) {
artifact 'test-1.1/abc-1.1.py'
version "1.5"
groupId "com.example"
artifactId "script"
}
}
}
artifactoryPublish {
publications ('mavenJava')
publishBuildInfo = false
publishArtifacts = false
publishPom = false
publishIvy = false
}
对于测试,我不想发布BuildInfo和Pom。尽管事实上所有发布都被设置为虚假调用
gradle clean generatePomFileForMavenJavaPublication artifactoryPublish
并观察http流量和控制台输出,确认所有上传仍在进行中。
Deploying artifact: https://artifactory/publish_repository_key/com/example/script/1.5/script-1.5.py
Deploying artifact: https://artifactory/publish_repository_key/com/example/script/1.5/script-1.5.pom
Error occurred for request PUT /publish_repository_key/com/example/script/1.5/script-1.5.pom.sha1;build.name=script;build.number=1512095807403 HTTP/1.1: Read timed out.
另外,上次错误完全让我困惑。