Skip to content

[Feature] minimal hub container image#145

Open
nissessenap wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
nissessenap:hub_container
Open

[Feature] minimal hub container image#145
nissessenap wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
nissessenap:hub_container

Conversation

@nissessenap
Copy link
Copy Markdown
Contributor

Add ko configuration and a GitHub Actions workflow to build, publish, and sign a multi-arch (amd64/arm64) hub container image on every tag push. The image uses a distroless base (cgr.dev/chainguard/static) and embeds the web frontend assets.

The image is published as ghcr.io/<owner>/scion:<tag> and tagged with both the version tag and latest.

Closes #133 (container image portion)

Fixes #<issue_number_goes_here>

It's a good idea to open an issue first for discussion.

  • Tests pass
  • Appropriate changes to documentation are included in the PR

@google-cla
Copy link
Copy Markdown

google-cla Bot commented Apr 12, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@nissessenap
Copy link
Copy Markdown
Contributor Author

Could argue we should updat docs to say that we provide a production based image for hub

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a ko configuration for building the scion container image and adds a ko-build-local target to the Makefile. The review feedback recommends pinning the base image in .ko.yaml to a specific version or SHA256 digest to ensure build reproducibility and security. Additionally, it is suggested to use the existing web target as a dependency in the Makefile to avoid duplicating the web frontend build logic.

Comment thread .ko.yaml Outdated
@@ -0,0 +1,16 @@
# ko configuration for building the scion hub/broker container image.
# See: https://ko.build/configuration/
defaultBaseImage: cgr.dev/chainguard/static:latest
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Using the :latest tag for the base image can lead to non-reproducible builds and potential supply chain security risks, as the underlying image can change without notice. It is recommended to pin the base image to a specific version or, even better, a SHA256 digest to ensure consistency across builds.

Comment thread Makefile Outdated
Comment on lines +95 to +97
ko-build-local:
@echo "Building web frontend for container..."
@cd web && npm install && npm run build
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The ko-build-local target manually re-implements the web frontend build logic. It is more maintainable to use the existing web target as a dependency to ensure consistency and avoid duplication.

ko-build-local: web

@nissessenap nissessenap force-pushed the hub_container branch 4 times, most recently from 3f27c10 to 4e8cc11 Compare April 13, 2026 05:07
Add ko configuration and a GitHub Actions workflow to build, publish,
and sign a multi-arch (amd64/arm64) hub container image on every tag
push. The image uses a distroless base (cgr.dev/chainguard/static)
and embeds the web frontend assets.

The image is published as `ghcr.io/<owner>/scion:<tag>` and tagged
with both the version tag and `latest`.

Closes GoogleCloudPlatform#133 (container image portion)

Signed-off-by: Edvin Norling <edvin.norling@kognic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Helm chart and minimal hub/broker container image for Kubernetes deployment

1 participant