-
Notifications
You must be signed in to change notification settings - Fork 213
nginx: add tests & fix failures for SSL_TYPE=upstream #1589
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
Conversation
| }); | ||
| socket.on('end', resolve); | ||
| socket.on('error', reject); | ||
| })); |
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.
These tests are specific to SSL_TYPE=selfsign, and have been moved above.
| res.on('error', reject); | ||
|
|
||
| const body = new Readable({ _read: () => {} }); | ||
| const body = new Readable({ read:() => {} }); |
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.
This was a bug, but only shows when the Readable is used with http.request, not with https.request.
| }); | ||
| socket.on('end', resolve); | ||
| socket.on('error', reject); | ||
| })); |
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.
These tests are specific to SSL_TYPE=selfsign, and have been moved up from below.
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.
Closes #1588
What has been done to verify that this works as intended?
Adapted existing nginx tests to run with both:
SSL_TYPE=selfsign(as happened previously), andSSL_TYPE=upstream(previously untested, as exposed in Update X-Forwarded-Proto directive in backend.conf #1586)Why is this the best possible solution? Were any other approaches considered?
This PR adapts existing tests and runs them for
SSL_TYPE=upstream. This is in addition toSSL_TYPE=selfsign, which was already being tested.This approach has shown its worth by exposing another bug with
SSL_TYPE=upstream, where/csp-report-related nginx config was being stripped by an overly-broadperlregex.How does this change affect users? Describe intentional changes to behavior and behavior that could have accidentally been affected by code changes. In other words, what are the regression risks?
Should reduce risk from nginx config changes for users using
SSL_TYPE=upstream.Does this change require updates to documentation? If so, please file an issue here and include the link below.
No.
Before submitting this PR, please make sure you have:
nextbranch OR only changed documentation/infrastructure (masteris stable and used in production)