Skip to content

Default the access proxy image to the chart's release - #1176

Merged
railgrid-prow[bot] merged 2 commits into
railgrid:mainfrom
mjudeikis:access-proxy-chart-version
Nov 17, 2026
Merged

railgrid-prow[bot] merged 2 commits into
railgrid:mainfrom
mjudeikis:access-proxy-chart-version

Conversation

@mjudeikis

Copy link
Copy Markdown
Contributor

Why

The infrastructure chart defaulted publishing.accessProxyImage to railgrid-access-proxy:latest. A deployment therefore either floated on :latest or pinned a tag by hand, and nothing moved that pin afterwards. Production follows a chart version range, so the provider kept upgrading while the access gate stayed on v0.2.1, the tag pinned at first install.

The gate image is already built and pushed on every providers/infrastructure/vX.Y.Z tag; only the chart default was missing.

What changes

A new infrastructure.accessProxyImage helper, modelled on the existing infrastructure.devAgentImage:

Chart accessProxyImage unset
Release package (appVersion vX.Y.Z) <accessProxyImageRepository>:vX.Y.Z
In-repo chart, or a main build (appVersion sha-<commit>) empty; the binary keeps its :latest default, since no gate image is published for these
Any chart with accessProxyImage set the explicit value
  • Both the serve Deployment (publishing.*) and the operator-managed InfrastructureProvider (operator.publishing.*) go through the helper.
  • New value accessProxyImageRepository in both blocks, for mirrors.
  • accessProxyImage now defaults to "" in values.yaml.
  • The operator CR's publishing: block is rendered unconditionally. Its old condition was always true because of the :latest default.
  • The self-hosting requiredValues entry in the chart's CatalogEntry uses the helper, falling back to :latest.

Upgrade note

A deployment that relied on the :latest default moves to the release tag on its next chart upgrade. A deployment that sets accessProxyImage is unaffected; removing that override lets the gate follow the chart.

Testing

  • helm template against the in-repo chart, a 0.0.0-main package and a 0.3.0 package: default, explicit override and repository override render as in the table, in both modes.
  • node hack/verify-provider-contract.mjs: 0 violations.
  • Not run locally: the new TestChartAccessProxyImageFollowsRelease and make lint (the provider module could not be compiled on a full disk). CI is the first run of the test.
  • Not rendered: the self-hosting requiredValues entry.

The infrastructure chart defaulted publishing.accessProxyImage to
railgrid-access-proxy:latest, so a deployment either floated on :latest
or pinned a tag by hand that nothing moved afterwards: a chart following
a version range upgraded the provider and left the gate on the tag of
its first install.

A released chart (appVersion vX.Y.Z) now resolves an empty
accessProxyImage to <accessProxyImageRepository>:vX.Y.Z, the gate the
same release publishes, in both the serve Deployment and the
operator-managed InfrastructureProvider. An explicit value still wins.
The in-repo chart and main builds (appVersion sha-<commit>) publish no
gate image and keep the binary's :latest default.
@mjudeikis
mjudeikis requested a review from cwilhit as a code owner November 16, 2026 12:47
Copilot AI balanced review requested due to automatic review settings November 16, 2026 12:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

The access-proxy template change is inconsistent with the generator, causing the existing byte-comparison test to fail and regeneration to revert the new helper call.

1 open issue
What changed in this PR

This PR makes the infrastructure provider’s access-proxy image follow the chart’s release version by default, keeping the access gate aligned with provider upgrades while preserving explicit image overrides.

Changes:

  • Adds release-aware image resolution for both deployment modes, with configurable repositories for mirrors.
  • Updates self-hosting defaults and documents release versus unreleased behavior.
  • Adds Helm rendering tests and clarifies release-workflow comments.
File Description
providers/​infrastructure/​deploy/​chart/​values.yaml Defaults image overrides to empty and adds repository settings.
providers/​infrastructure/​deploy/​chart/​templates/​operator-config.yaml Uses the helper and always renders publishing configuration.
providers/​infrastructure/​deploy/​chart/​templates/​deployment.yaml Resolves the access-proxy environment variable through the helper.
providers/​infrastructure/​deploy/​chart/​templates/​catalogentry.yaml Applies release-aware self-hosting defaults with a :latest fallback.
providers/​infrastructure/​deploy/​chart/​templates/​_helpers.tpl Adds shared release-aware image resolution.
providers/​infrastructure/​deploy/​chart/​README.md Documents image defaults and repository overrides.
providers/​infrastructure/​chart_access_proxy_image_test.go Tests release, unreleased, explicit-image, and mirror behavior.
.github/​workflows/​provider-release.yaml Clarifies image-version expectations in comments only.

Review effort: Balanced

it ends up in a redirect the user's browser follows.
- name: operator.publishing.accessProxyImage
value: {{ .Values.publishing.accessProxyImage | quote }}
value: {{ include "infrastructure.accessProxyImage" (dict "ctx" . "publishing" .Values.publishing) | default (printf "%s:latest" (default "ghcr.io/railgrid/railgrid-access-proxy" (default (dict) .Values.publishing).accessProxyImageRepository)) | quote }}
@cwilhit

cwilhit commented Nov 16, 2026

Copy link
Copy Markdown
Collaborator

/test pull-railgrid-test-providers

@cwilhit

cwilhit commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

/approve

@railgrid-prow

railgrid-prow Bot commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cwilhit

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@mjudeikis

Copy link
Copy Markdown
Contributor Author

/test all

@railgrid-prow
railgrid-prow Bot merged commit df92b03 into railgrid:main Nov 17, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants