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

Support HTTP proxy env variables #4769

Merged
merged 8 commits into from Sep 22, 2023
Merged

Conversation

pavolloffay
Copy link
Member

@pavolloffay pavolloffay commented Sep 21, 2023

Support HTTP proxy variables (some docs https://superuser.com/questions/944958/are-http-proxy-https-proxy-and-no-proxy-environment-variables-standard).

The codebase already supports it, but some places were missed. There were also two problems:

  1. query grpc gateway was connecting to :16686 which is not recognized by NO_PROXY
  2. grpc reporter in agent when used with all-in-one was connecting to :14250 also not recognized by NO_PROXY

Example of proxy vars set on OpenShift

 - name: HTTP_PROXY
              value: >-
                http://proxy-user1:foo@ec2-32-138-32-212.us-east-2.compute.amazonaws.com:3128
            - name: http_proxy
              value: >-
                http://proxy-user1:foo@ec2-32-138-32-212.us-east-2.compute.amazonaws.com:3128
            - name: HTTPS_PROXY
              value: >-
                http://proxy-user1:foo@ec2-32-138-32-221.us-east-2.compute.amazonaws.com:3128
            - name: https_proxy
              value: >-
                http://proxy-user1:foo@ec2-32-138-32-212.us-east-2.compute.amazonaws.com:3128
            - name: NO_PROXY
              value: >-
                .cluster.local,.svc,.us-east-2.compute.internal,10.0.0.0/16,10.128.0.0/14,127.0.0.1,169.254.169.254,172.30.0.0/16,api-int.rererer.qe.devcluster.openshift.com,localhost,test.no-proxy.com
            - name: no_proxy
              value: >-
                .cluster.local,.svc,.us-east-2.compute.internal,10.0.0.0/16,10.128.0.0/14,127.0.0.1,169.254.169.254,172.30.0.0/16,api-int.rerererer.qe.devcluster.openshift.com,localhost,test.no-proxy.com

PR is related to jaegertracing/jaeger-operator#2330

make build-binaries-linux
DOCKER_NAMESPACE=pavolloffay DOCKER_TAG=proxy-3 make docker-images-jaeger-backend

Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
@codecov
Copy link

codecov bot commented Sep 21, 2023

Codecov Report

Patch coverage is 100.00% of modified lines.

Files Changed Coverage
cmd/agent/app/reporter/grpc/builder.go 100.00%
cmd/query/app/apiv3/grpc_gateway.go 100.00%
pkg/netutils/port.go 100.00%

📢 Thoughts on this report? Let us know!.

Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
@yurishkuro yurishkuro closed this Sep 21, 2023
@yurishkuro yurishkuro reopened this Sep 21, 2023
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

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

lgtm

cmd/agent/app/reporter/grpc/builder.go Outdated Show resolved Hide resolved
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
@pavolloffay pavolloffay marked this pull request as ready for review September 22, 2023 07:33
@pavolloffay pavolloffay requested a review from a team as a code owner September 22, 2023 07:33
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
Signed-off-by: Pavol Loffay <p.loffay@gmail.com>
@pavolloffay
Copy link
Member Author

@yurishkuro could you please re-review?

@yurishkuro yurishkuro merged commit af70f26 into jaegertracing:main Sep 22, 2023
31 checks passed
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.

None yet

2 participants