Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Handle use of provide config from environment variables #29

Merged
merged 1 commit into from
May 28, 2024

Conversation

grahamhar
Copy link
Contributor

@grahamhar grahamhar commented May 16, 2024

Hi,

This is an attempt to fix the issues seen by @jackmtpt when trying to configure the provider via environment variable.

Tests are added for the error scenarios, but the warning can't be tested see this issue.

Output of warning from a manual test where the environment variable and the provider config for url were provided.

╷
│ Warning: Provider config override
│ 
│   with provider["registry.terraform.io/hashicorp/sonatypeiq"],
│   on provider.tf line 21, in provider "sonatypeiq":
│   21: provider "sonatypeiq" {
│ 
│ The provider config is overriding the environment variable `IQ_SERVER_URL`
│ 
│ (and one more similar warning elsewhere)
╵

close: #26

@grahamhar grahamhar force-pushed the fix-provider branch 2 times, most recently from 44d0c11 to edaef04 Compare May 17, 2024 15:47
@grahamhar grahamhar marked this pull request as ready for review May 17, 2024 15:48
@grahamhar grahamhar requested a review from madpah as a code owner May 17, 2024 15:48
@sonatype-community-cla-app
Copy link

sonatype-community-cla-app bot commented May 28, 2024

CLA assistant check
All committers have signed the CLA.

Signed-off-by: grahamhar <grahamhar@users.noreply.github.com>
@madpah
Copy link
Collaborator

madpah commented May 28, 2024

Merging to main to run Acceptance Tests

@madpah madpah merged commit 55c41cd into sonatype-nexus-community:main May 28, 2024
2 of 8 checks passed
@madpah
Copy link
Collaborator

madpah commented May 28, 2024

Tests all green - thanks again @grahamhar.

@grahamhar grahamhar deleted the fix-provider branch May 28, 2024 15:47
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.

Environment variable config not working
2 participants