-
Notifications
You must be signed in to change notification settings - Fork 450
[terraform] Add Custom Download Server Support for Terraform Dev Container Feature #1364
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
base: main
Are you sure you want to change the base?
[terraform] Add Custom Download Server Support for Terraform Dev Container Feature #1364
Conversation
…uire full URL with protocol
4f13686
to
7f654ca
Compare
@microsoft-github-policy-service agree |
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.
Changes are fine & test scenarios validated. To be further reviewed by maintainers.
@Kaniska244 can you tell me approximately how long I need to wait for maintainers? Maybe I should write to someone asking them to view this PR? |
}, | ||
"custom_download_server": { | ||
"image": "mcr.microsoft.com/devcontainers/base:jammy", | ||
"features": { | ||
"terraform": { | ||
"version": "1.6.5", | ||
"customDownloadServer": "https://releases.hashicorp.com" | ||
} | ||
} | ||
}, |
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.
Since the default is already "https://releases.hashicorp.com"
, this test makes the case that adding it does not break functionality. However, I would like to test that it does override - I can see from the code that it does, but still would be good to systematically test it. Would you be able to make an additional test with a fake URL and expect that it fails please?
This pull request introduces the ability to specify a custom download server for the Terraform Dev Container feature. This enhancement is particularly useful for organizations that maintain internal mirrors or have proxies for HashiCorp downloads, allowing them to control the source of Terraform and Sentinel packages.
Key Changes:
customDownloadServer
in thedevcontainer-feature.json
to allow users to specify an alternative server URL.install.sh
script to utilize the custom server URL when provided, ensuring that the download process respects the user's configuration.NOTES.md
to include guidelines on using the custom download server, along with security considerations to ensure users are aware of potential risks.Motivation:
Testing:
scenarios.json
to include cases for custom download server usage, ensuring that the feature works as expected with different configurations.