Closed artembilan closed 1 week ago
Steps to reproduce:
Clone the example gradle project from JFrog project-examples GitHub page.
Generate a new GPG key.
Inside the project directory modify the build.gradle file as follows:
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath(group: 'org.jfrog.buildinfo', name: 'build-info-extractor-gradle', version: '4.+')
}
}
allprojects {
apply plugin: 'signing'
tasks.register('artifactoryPublish', org.jfrog.gradle.plugin.artifactory.task.ArtifactoryTask) {
setCiServerBuild()
}
apply plugin: org.jfrog.gradle.plugin.artifactory.ArtifactoryPlugin
repositories {
maven {
url "<Artifactory URL>/artifactory/<remote reposiotry>"
}
}
}
version = currentVersion
apply plugin: 'com.jfrog.artifactory' apply plugin: 'java' apply plugin: 'maven-publish'
dependencies { testImplementation 'junit:junit:4.7' }
publishing { publications { mavenJava(MavenPublication) { from components.java } } }
artifactory {
contextUrl = '
4. Modify the gradle.properties file:
``` currentVersion=1.0-SNAPSHOT
artifactory_user=<Artifactory username>
artifactory_password=<Artifactory password>
signing.keyId=<KeyID> /last 8 digits of your gpg key, get by running “gpg --list-keys --keyid-format short”
signing.password=<passpharse for the GPG key>
signing.secretKeyRingFile=<path to the GPG key>
Hi @artembilan @RoiNiv23 , Artifactory Gradle Plugin 5.2.3 was just released and includes a fix for this issue. We'd appreciate your feedback for it.
Looks like that works and I see published .asc
files as well.
This issue can be closed.
Thank you!
Thanks for the feedback @artembilan !
Describe the bug
The goal is to sign artifacts before they are published to the Artifactory. It works well with plugin of version
4+
, but does not with5+
.Current behavior
This my Gradle init script:
Works well and as expected: the artifacts are signed and
.asc
files are uploaded to the Artifactory alongside with other artifacts.If I change
build-info-extractor-gradle
version to the5+
it does not sing artifacts. And even if I makeartifactoryPublish
dependent onsignMavenJavaPublication
tasks and it is called, the.asc
files are not uploaded to the Artifactory.Reproduction steps
No response
Expected behavior
No response
Artifactory Gradle plugin version
5+
Operating system type and version
GitHub Actions
JFrog Artifactory version
No response
Gradle version
8.5