From 56f11bde4c72e0e1c9ad323900e00075fc7b21c7 Mon Sep 17 00:00:00 2001 From: Ross Ceballo Date: Thu, 23 Jan 2025 12:04:05 -0500 Subject: [PATCH] Add buildx to docker --- pipelines/release/docker/build_stack.groovy | 66 +++++++++++++-------- 1 file changed, 42 insertions(+), 24 deletions(-) diff --git a/pipelines/release/docker/build_stack.groovy b/pipelines/release/docker/build_stack.groovy index 10c65892..81f31def 100644 --- a/pipelines/release/docker/build_stack.groovy +++ b/pipelines/release/docker/build_stack.groovy @@ -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) { @@ -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, @@ -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