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 client ip in envoy logs #258

Merged
merged 2 commits into from
Apr 28, 2023
Merged

Fix client ip in envoy logs #258

merged 2 commits into from
Apr 28, 2023

Conversation

roivaz
Copy link
Member

@roivaz roivaz commented Apr 28, 2023

We were taking the remote address from the X-ENVOY-EXTERNAL-ADDRESS envoy header, which is not even added when http/1.0 requests are rejected, so the field was empty in the logs. Using the internal variable DOWNSTREAM_REMOTE_ADDRESS_WITHOUT_PORT fixes this and remote address is also logged for rejected requests.

/kind bug
/priority important-soon
/assign

@3scale-robot 3scale-robot added kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next sprint. needs-size Indicates a PR or issue lacks a `size/foo` label and requires one. labels Apr 28, 2023
@3scale-robot 3scale-robot requested review from raelga and slopezz April 28, 2023 10:04
@3scale-robot 3scale-robot added size/S Requires less than a day to complete the PR or the issue. and removed needs-size Indicates a PR or issue lacks a `size/foo` label and requires one. labels Apr 28, 2023
@slopezz
Copy link
Member

slopezz commented Apr 28, 2023

/lgtm

@3scale-robot 3scale-robot added the lgtm Indicates that a PR is ready to be merged. label Apr 28, 2023
@3scale-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: a6a892bfe1dcf26eca0c12a98821a05a9e241ad3

@raelga
Copy link
Contributor

raelga commented Apr 28, 2023

/lgtm

@roivaz roivaz force-pushed the fix-client-ip-in-logs branch from 0fec493 to 4f51320 Compare April 28, 2023 10:22
@3scale-robot 3scale-robot removed the lgtm Indicates that a PR is ready to be merged. label Apr 28, 2023
@roivaz roivaz force-pushed the fix-client-ip-in-logs branch from 4f51320 to 91ea529 Compare April 28, 2023 10:33
@roivaz roivaz added the lgtm Indicates that a PR is ready to be merged. label Apr 28, 2023
@roivaz
Copy link
Member Author

roivaz commented Apr 28, 2023

/approve

@3scale-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: roivaz

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@3scale-robot 3scale-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 28, 2023
@3scale-robot 3scale-robot merged commit 8f2959a into main Apr 28, 2023
@3scale-robot 3scale-robot deleted the fix-client-ip-in-logs branch April 28, 2023 10:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next sprint. size/S Requires less than a day to complete the PR or the issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants