GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(terraform): include registry hostname in autodiscovery manifest by Pankaj-Gupta25 · Pull Request #9281 · updatecli/updatecli

Conversation

@Pankaj-Gupta25

@Pankaj-Gupta25 Pankaj-Gupta25 commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

This fixes an issue where the Terraform autodiscovery plugin drops the hostname for non-default registries (like OpenTofu) and falls back to registry.terraform.io.

Fix #9232

When generating the updatecli manifest, the Terraform autodiscovery plugin was omitting the hostname field for the terraform/registry source configuration. Because of this, Updatecli would default to registry.terraform.io, causing it to throw a 404 error when trying to resolve providers hosted on alternative registries like registry.opentofu.org.

This PR uses the terraformRegistryAddress parser to extract the exact hostname from the provider string inside .terraform.lock.hcl. It then explicitly injects the hostname field into the generated manifest template if the hostname differs from the default registry.terraform.io.

Test

To test this pull request, you can run the following commands:

cd pkg/plugins/autodiscovery/terraform
go test

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@pankaj-gupta-av
fix(terraform): include registry hostname in autodiscovery manifest
2b66597
This fixes an issue where the Terraform autodiscovery plugin drops the hostname for non-default registries (like OpenTofu) and falls back to registry.terraform.io.
@Pankaj-Gupta25
Pankaj-Gupta25 marked this pull request as draft June 26, 2026 20:43
@Pankaj-Gupta25
Pankaj-Gupta25 marked this pull request as ready for review June 26, 2026 20:43
@Pankaj-Gupta25 Pankaj-Gupta25 mentioned this pull request Jun 28, 2026
Failure to resolve REGISTRY.OPENTOFU.ORG/OPENTFFOUNDATION/* #9232
Closed
1 task done
olblak
olblak approved these changes Jun 28, 2026
View reviewed changes

@olblak olblak left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thank you for the pullrequest.
This sounds good to me, could you confirm that you tested

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@olblak olblak added bug Something isn't working autodiscovery All things related to the autodiscovery feature resource-terraform labels Jun 28, 2026
@olblak
olblak enabled auto-merge (squash) June 28, 2026 18:10
@olblak
olblak merged commit c095a1f into updatecli:main Jun 28, 2026
8 checks passed

Uh oh!

There was an error while loading. Please reload this page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@olblak olblak olblak approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

autodiscovery All things related to the autodiscovery feature bug Something isn't working resource-terraform

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Failure to resolve REGISTRY.OPENTOFU.ORG/OPENTFFOUNDATION/*

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@Pankaj-Gupta25 @olblak @pankaj-gupta-av
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.