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

Unable to use HTTP_PROXY and HTTPS_PROXY env variable #103

Open
mhussain584 opened this issue Jul 24, 2024 · 1 comment
Open

Unable to use HTTP_PROXY and HTTPS_PROXY env variable #103

mhussain584 opened this issue Jul 24, 2024 · 1 comment

Comments

@mhussain584
Copy link

mhussain584 commented Jul 24, 2024

I have a use case where i am using an external proxy to pull the metrics, and currently using the both HTTP_PROXY and HTTPS_PROXY while running the agent.

docker run -p 8083:8083 -p 8093:8093 --mount type=bind,source="$(pwd)"/prom-agent.conf,target=/app/prom-agent.conf --env HTTP_PROXY=https://proxium-us-east-1.aws-dev.abc.com:3128 --env HTTPS_PROXY=https://proxium-us-east-1.aws-dev.abc.com:3128 --env AGENT_CONFIG=prom-agent.conf --env DEBUG_ENABLED=true --network host -d pambrose/prometheus-agent:1.21.0

Opened required ports from host and destination machines, and validated the connectivity to proxy from the agent node machine works fine.

When i try to start the agent with the above variables it is somehow unable to read it from the variable.

10:58:20.304 INFO [AgentGrpcService.kt:186] - Cannot connect to proxy at prom-proxy.aws-dev.abc.com:50051 using plaintext - StatusException: UNAVAILABLE: io exception [Agent Unnamed-ip-100-120-14-241.ec2.internal] 10:58:23.296 INFO [Agent.kt:211] - Waited 3s to reconnect [Agent Unnamed-ip-100-120-14-241.ec2.internal] 10:58:23.297 INFO [AgentGrpcService.kt:175] - Connecting to proxy at prom-proxy.aws-dev.abc.com:50051 using plaintext... [Agent Unnamed-ip-100-120-14-241.ec2.internal]

Configured the proxy_hostname in the agent.conf
proxy.hostname = prom-proxy.aws-dev.abc.com

Not sure what i am missing here, but any help would be appreciated.

Thanks

@pambrose
Copy link
Owner

Hi,

I just saw this issue. I am not sure how/why I missed the notification. Sorry about that. Did you resolve this issue?

Paul

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

No branches or pull requests

2 participants