Extracted platform config to platforms.json and automated image updates#2161
Merged
olehermanse merged 6 commits intocfengine:masterfrom Apr 8, 2026
Merged
Extracted platform config to platforms.json and automated image updates#2161olehermanse merged 6 commits intocfengine:masterfrom
olehermanse merged 6 commits intocfengine:masterfrom
Conversation
Extracted PLATFORMS and IMAGE_VERSION from build-in-container.py into a flat platforms.json file, loaded via a cached get_config() function. Each platform now has separate image_name and image_version fields (split from image_tag), and extra_build_args can be omitted when empty. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
Pinned each base image to a specific digest for reproducible builds. The digest is appended to the base_image reference when passed to docker build. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
Replaced the manual version bump check with automatic timestamp-based versioning (e.g., 20260408T153042Z) when pushing images. Removed the now-unused image_exists_in_registry function. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
The workflow now runs every Sunday at midnight UTC to keep base images up to date with the latest upstream packages. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
Queries the ghcr.io registry API for the latest tags and updates image_version in platforms.json. Supports --platform to update a single platform, or updates all when omitted. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
Runs every Monday at midnight and creates a PR if platforms.json was updated with newer image tags. Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
olehermanse
reviewed
Apr 8, 2026
| log.error("Docker push failed.") | ||
| sys.exit(1) | ||
|
|
||
| log.info(f"Update image_version to \"{version}\" in platforms.json.") |
Member
There was a problem hiding this comment.
Suggested change
| log.info(f"Update image_version to \"{version}\" in platforms.json.") | |
| log.info(f"Updated image_version to \"{version}\" in platforms.json.") |
olehermanse
approved these changes
Apr 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
platforms.json--push-imageto use UTC timestamp versions instead of manual bumps--updateflag to fetch latest image versions from the ghcr.io registryplatforms.jsonand create a PR (Monday)🤖 Generated with Claude Code