Skip to content

Commit

Permalink
fix signing
Browse files Browse the repository at this point in the history
Signed-off-by: Luis Pinto <[email protected]>
  • Loading branch information
lu-pinto committed Dec 19, 2024
1 parent df0537c commit 650a461
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions dist/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -193,30 +193,36 @@ distTar { compression = Compression.GZIP }

sourcesDistTar { compression = Compression.GZIP }

artifacts {
archives distZip
archives distTar
archives sourcesDistZip
archives sourcesDistTar
}

if (System.getenv('ENABLE_SIGNING') == 'true') {
signing {
useGpgCmd()
sign distributions.main.allArtifacts
sign distributions.sources.allArtifacts
sign configurations.archives
sign distZip
sign distTar
sign sourcesDistZip
sign sourcesDistTar
}
}

task createChecksums(type: Checksum, dependsOn: [
'distZip',
'distTar',
'sourcesDistZip',
'sourcesDistTar',
]) {
task createChecksums(type: Checksum) {
dependsOn tasks.withType(Sign), 'distZip', 'distTar', 'sourcesDistZip', 'sourcesDistTar'

files = distZip.outputs.files + distTar.outputs.files + sourcesDistZip.outputs.files + sourcesDistTar.outputs.files
outputDir = new File(project.buildDir, "distributions")
algorithm = Checksum.Algorithm.SHA512
}

build.dependsOn('createChecksums')
if (System.getenv('ENABLE_SIGNING') == 'true') {
build.dependsOn tasks.withType(Sign)
}

task buildBinImage(type: DockerBuildImage) {
dependsOn distTar
Expand Down

0 comments on commit 650a461

Please sign in to comment.