Skip to content

chore: Fetch latest version from the image registry and not from github#1615

Merged
JoshVanL merged 2 commits into
dapr:masterfrom
acroca:versions-from-image-registry
Apr 6, 2026
Merged

chore: Fetch latest version from the image registry and not from github#1615
JoshVanL merged 2 commits into
dapr:masterfrom
acroca:versions-from-image-registry

Conversation

@acroca

@acroca acroca commented Mar 30, 2026

Copy link
Copy Markdown
Member

Close: #1575

When providing --image-registry the CLI still makes http requests to github to figure out latest versions.

In this PR I make it fetch the versions from the image tags from the image registry directly.

@acroca

acroca commented Mar 30, 2026

Copy link
Copy Markdown
Member Author

Waiting for #1613 to upgrade Go and golangci-lint

@acroca
acroca force-pushed the versions-from-image-registry branch from af55e87 to c4ff54c Compare April 1, 2026 11:49
@acroca
acroca force-pushed the versions-from-image-registry branch from c4ff54c to 6439f14 Compare April 1, 2026 11:50
@acroca
acroca marked this pull request as ready for review April 1, 2026 13:27
@acroca
acroca requested review from a team as code owners April 1, 2026 13:27
@JoshVanL
JoshVanL requested a review from Copilot April 1, 2026 13:28

Copilot AI left a comment

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.

Pull request overview

This PR changes how the CLI determines the “latest” Dapr runtime/dashboard versions, switching from GitHub/Helm-based lookups to querying container image tags directly from a registry (especially when --image-registry is provided), aiming to avoid GitHub network calls.

Changes:

  • Replace GitHub/Helm version discovery with registry tag listing via go-containerregistry.
  • Update standalone + Kubernetes init flows to use registry-derived latest versions.
  • Update unit/e2e tests and add new dependency (go-containerregistry) plus module tidy updates.

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
pkg/version/version.go Implements latest-version resolution by listing image tags from a registry; adds default image refs + helpers.
pkg/standalone/standalone.go Uses registry-derived latest versions for standalone init when latest is requested.
pkg/kubernetes/kubernetes.go Uses registry-derived latest versions for Helm installs, respecting ImageRegistryURI.
pkg/version/version_test.go Replaces GitHub/Helm tests with an in-memory OCI registry-based test suite.
tests/e2e/standalone/init_test.go Updates e2e expectations for “no version specified” flows to use the new latest-version lookup.
go.mod / go.sum Adds go-containerregistry and updates a set of (some unrelated) dependencies.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pkg/standalone/standalone.go
Comment thread pkg/standalone/standalone.go
Comment thread pkg/version/version_test.go
Comment thread tests/e2e/standalone/init_test.go Outdated
Comment thread tests/e2e/standalone/init_test.go Outdated
Comment thread go.mod
Signed-off-by: Albert Callarisa <[email protected]>
@JoshVanL
JoshVanL merged commit 1c7e715 into dapr:master Apr 6, 2026
25 of 27 checks passed
@acroca
acroca deleted the versions-from-image-registry branch April 7, 2026 09:09
@github-project-automation github-project-automation Bot moved this from Backlog to Done in v1.18 Release Tracking Board May 4, 2026
@nelson-parente nelson-parente added this to the v1.18 milestone May 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

--image-registry during dapr init not fully offline

4 participants