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

Configuration of remote state ignores HTTP proxy #9403

Closed
jwadolowski opened this issue Oct 17, 2016 · 7 comments
Closed

Configuration of remote state ignores HTTP proxy #9403

jwadolowski opened this issue Oct 17, 2016 · 7 comments
Labels
bug v0.7 Issues (primarily bugs) reported against v0.7 releases

Comments

@jwadolowski
Copy link

Terraform Version

$ terraform -v
Terraform v0.7.6

Affected Resource(s)

N/A

Terraform Configuration Files

N/A

Debug Output

https://gist.github.com/jwadolowski/cd966c01b060f00c3fd69e5421484635

Expected Behavior

Terraform should respect http_proxy and https_proxy environment variables (as mentioned here)

Actual Behavior

$ env | grep http_
http_proxy=http://localhost:8118

Despite of above, I can't see any HTTP request coming through my proxy server. At the same time curl and other HTTP clients respecting http_proxy variable work fine.

Steps to Reproduce

  1. Configure http_proxy variable to point at actual proxy server
  2. Try to move local state to remote one via terraform remote config command (details in attached gist)

Important Factoids

All outgoing HTTP traffic needs to go through defined proxy.

References

@jbardin jbardin added bug dependencies Auto-pinning labels Oct 19, 2016
@jbardin
Copy link
Member

jbardin commented Oct 19, 2016

Hi,

Thanks for reporting this issue. This looks like a bug in the artifactory client that terraform uses. We'll see if we can get this fixed upstream.

@brandongalbraith
Copy link
Contributor

@jbardin Any update on having this resolved upstream?

@jbardin
Copy link
Member

jbardin commented May 24, 2017

It looks like the current version is still using an empty http.Transport.

Regardless of whether this gets fixed or not (I opened a new issue upstream), we can probably just inject our own Transport into the config.

@arsdehnel
Copy link
Contributor

This is a pretty big blocker for us expanding our use of Terraform at my company. It means we're having to get off the network to run Terraform so we can just shut off our proxy settings entirely and that's not a long-term acceptable solution to some folks in our org. Any idea of priority on this or an ETA?

@apparentlymart
Copy link
Member

Unfortunately at this time the Terraform team at HashiCorp isn't able to work on this due to other tasks, and due to the fact that we don't have an artifactory setup handy to test such a change with.

However, if someone else who does already have an artifactory account and has the time and willingness to work on this, we'd love to review a Pull Request. It looks like the work here would be to pass in an explicit transport where the artifactory client is instantiated and configure that http.Transport object use http.ProxyFromEnvironment as its proxy function.

@hashibot hashibot added the v0.7 Issues (primarily bugs) reported against v0.7 releases label Aug 29, 2019
@mildwonkey
Copy link
Contributor

The linked PR should have closed this issue, so I am going to do so now. Thanks!

@ghost
Copy link

ghost commented Oct 13, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked as resolved and limited conversation to collaborators Oct 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug v0.7 Issues (primarily bugs) reported against v0.7 releases
Projects
None yet
Development

No branches or pull requests

7 participants