Skip to content

Commit

Permalink
Add buildx to docker
Browse files Browse the repository at this point in the history
  • Loading branch information
roceb committed Jan 23, 2025
1 parent c10265b commit 56f11bd
Showing 1 changed file with 42 additions and 24 deletions.
66 changes: 42 additions & 24 deletions pipelines/release/docker/build_stack.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -115,36 +115,18 @@ notify.wrap {
opt << "--load"
opt << '.'

sh("docker buildx version")

dir(buildDir) {
image = docker.build("${dockerRepo}", opt.join(' '))
image2 = docker.build("panda-dev-1a74/${dockerRepo}", opt.join(' '))
image3 = docker.build("lsstsqre/almalinux", opt.join(' '))
}
}
def sha = image.inspect()
println(sha)
println(image)

stage('push') {
if (!noPush) {
docker.withRegistry(
'https://index.docker.io/v1/',
'dockerhub-sqreadmin'
) {
registryTags.each { name ->
image.push(name)
}
newRegistryTags.each { name ->
image3.push(name)
}
}
docker.withRegistry(
'https://us-central1-docker.pkg.dev/',
'google_archive_registry_sa'
) {
registryTags.each { name ->
image2.push(name)
}
}
}
} // push
} // run

util.nodeWrap(lsstswConfig.label) {
Expand All @@ -154,10 +136,11 @@ notify.wrap {
}
} finally {
stage('archive') {
def resultsFile = 'results.json'
def resultsFile = lsstswConfig.displayname + 'results.json'

util.dumpJson(resultsFile, [
base_image: baseImage ?: null,
digest: "0",
image: "${dockerRepo}:${dockerTag}",
docker_registry: [
repo: dockerRepo,
Expand All @@ -176,4 +159,39 @@ notify.wrap {
}
parallel matrix

def merge = {
stage('digest'){

}
stage('push') {
if (!noPush) {
docker.withRegistry(
'https://index.docker.io/v1/',
'dockerhub-sqreadmin'
) {
registryTags.each { name ->
image.push(name)
}
newRegistryTags.each { name ->
image3.push(name)
}
}
docker.withRegistry(
'https://us-central1-docker.pkg.dev/',
'google_archive_registry_sa'
) {
registryTags.each { name ->
image2.push(name)
}
}
}
} // push

} // merge
util.nodeWrap('docker') {
timeout(time: timelimit, unit: 'HOURS') {
merge()
}
} // nodeWrap

} // notify.wrap

0 comments on commit 56f11bd

Please sign in to comment.