Skip to content

Commit

Permalink
HV-**** Use env variable name instead of the passphrase in GPG config…
Browse files Browse the repository at this point in the history
…uration
  • Loading branch information
marko-bekhta committed May 16, 2024
1 parent aee1e0f commit 9d82106
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion jenkins/release.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ pipeline {
mavenLocalRepo: env.WORKSPACE_TMP + '/.m2repository') {
configFileProvider([configFile(fileId: 'release.config.ssh', targetLocation: env.HOME + '/.ssh/config'),
configFile(fileId: 'release.config.ssh.knownhosts', targetLocation: env.HOME + '/.ssh/known_hosts')]) {
// using MAVEN_GPG_PASSPHRASE (the default env variable name for passphrase in maven gpg plugin)
withCredentials([file(credentialsId: 'release.gpg.private-key', variable: 'RELEASE_GPG_PRIVATE_KEY_PATH'),
string(credentialsId: 'release.gpg.passphrase', variable: 'RELEASE_GPG_PASSPHRASE')]) {
string(credentialsId: 'release.gpg.passphrase', variable: 'MAVEN_GPG_PASSPHRASE')]) {
sshagent(['ed25519.Hibernate-CI.github.com', 'hibernate.filemgmt.jboss.org', 'hibernate-ci.frs.sourceforge.net']) {
sh 'cat $HOME/.ssh/config'
sh 'git clone https://github.com/hibernate/hibernate-noorm-release-scripts.git'
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1377,7 +1377,7 @@
</goals>
<configuration>
<homedir>${env.RELEASE_GPG_HOMEDIR}</homedir>
<passphrase>${env.RELEASE_GPG_PASSPHRASE}</passphrase>
<bestPractices>true</bestPractices>
</configuration>
</execution>
</executions>
Expand Down

0 comments on commit 9d82106

Please sign in to comment.