Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
4efe405
Combined Dockerfiles
MaciejKaras Jun 2, 2025
d5c8a14
First script draft
Julien-Ben Jun 12, 2025
8dbf967
Copied pipeline, removed daily builds and --exclude
Julien-Ben Jun 18, 2025
406eb01
Remove pin_at and build_id
Julien-Ben Jun 18, 2025
988b91b
Remove namespace
Julien-Ben Jun 18, 2025
17afb28
Replace usage of sonar
Julien-Ben Jun 18, 2025
4683148
WIP, passing builds on staging temp + multi arch manifests
Julien-Ben Jun 18, 2025
ebaff31
Split in multiple files, cleanup
Julien-Ben Jun 20, 2025
0f4602a
Add documentation
Julien-Ben Jun 20, 2025
68b8048
Replace old by new pipeline in EVG
Julien-Ben Jul 9, 2025
213be89
Explicit image type, support custom build_path
Julien-Ben Jul 9, 2025
6de1000
Lint
Julien-Ben Jul 9, 2025
14c5391
All images build pass on EVG
Julien-Ben Jul 11, 2025
d826eaf
Renaming, usage of high level config
Julien-Ben Jul 11, 2025
46419b8
Handle build env
Julien-Ben Jul 11, 2025
93f590d
Add buildscenario to buildconfig
Julien-Ben Jul 11, 2025
35be53e
Adapt main to new build config
Julien-Ben Jul 11, 2025
75eff91
Some cleaning and version adjustments
Julien-Ben Jul 11, 2025
39110b0
black formatting
Julien-Ben Jul 11, 2025
2a736e1
Import sort
Julien-Ben Jul 11, 2025
f8c7976
Fix init appdb image
Julien-Ben Jul 14, 2025
dc83f5e
Implement is_release_step_executed()
Julien-Ben Jul 14, 2025
16a9973
TODOs
Julien-Ben Jul 14, 2025
4a822f9
Multi platform builds, with buildx
Julien-Ben Jul 22, 2025
ecf87e8
Rename MCO test image
Julien-Ben Jul 24, 2025
026697f
Remove --include
Julien-Ben Jul 24, 2025
9542012
Fix
Julien-Ben Jul 24, 2025
4570e54
Use legacy and new pipeline
Julien-Ben Jul 25, 2025
91dd191
Pass Build Configuration object directly
Julien-Ben Jul 25, 2025
87840ad
missed
Julien-Ben Jul 25, 2025
8640cb6
Simplify main and build_context
Julien-Ben Jul 25, 2025
92d62fa
Continue improvement to main
Julien-Ben Jul 25, 2025
965302d
Remove create and push manifests
Julien-Ben Jul 25, 2025
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Remove create and push manifests
  • Loading branch information
Julien-Ben committed Jul 25, 2025
commit 965302d78736a69f6ec3832d78ea1667b5c702d2
50 changes: 2 additions & 48 deletions scripts/release/atomic_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,16 @@
import json
import os
import shutil
import subprocess
import time
from concurrent.futures import ProcessPoolExecutor
from queue import Queue
from typing import Callable, Dict, Iterable, List, Optional, Tuple, Union
from typing import Callable, Dict, List, Optional, Tuple, Union

import requests
import semver
from opentelemetry import trace
from packaging.version import Version

import docker

from lib.base_logger import logger
from scripts.evergreen.release.agent_matrix import (
get_supported_operator_versions,
Expand Down Expand Up @@ -71,50 +69,6 @@ def load_release_file() -> Dict:
return json.load(release)


def create_and_push_manifest(image: str, tag: str, architectures: list[str]) -> None:
"""
Generates docker manifests by running the following commands:
1. Clear existing manifests
docker manifest rm config.repo_url/image:tag
2. Create the manifest
docker manifest create config.repo_url/image:tag --amend config.repo_url/image:tag-amd64 --amend config.repo_url/image:tag-arm64
3. Push the manifest
docker manifest push config.repo_url/image:tag

This method calls docker directly on the command line, this is different from the rest of the code which uses
Sonar as an interface to docker. We decided to keep this asymmetry for now, as Sonar will be removed soon.
"""
logger.debug(f"image: {image}, tag: {tag}, architectures: {architectures}")
final_manifest = image
logger.debug(f"push_manifest - final_manifest={final_manifest}")

args = [
"docker",
"manifest",
"create",
final_manifest,
]

for arch in architectures:
logger.debug(f"push_manifest - amending {final_manifest}:{tag}-{arch}")
args.extend(["--amend", f"{final_manifest}:{tag}-{arch}"])

args_str = " ".join(args)
logger.debug(f"creating new manifest: {args_str}")
cp = subprocess.run(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE)

if cp.returncode != 0:
raise Exception(cp.stderr)

args = ["docker", "manifest", "push", final_manifest]
args_str = " ".join(args)
logger.info(f"pushing new manifest: {args_str}")
cp = subprocess.run(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE)

if cp.returncode != 0:
raise Exception(cp.stderr)


@TRACER.start_as_current_span("sonar_build_image")
def pipeline_process_image(
image_name: str,
Expand Down