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

chore: add test for EG cert rotation #4944

Draft
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

guydc
Copy link
Contributor

@guydc guydc commented Dec 17, 2024

What type of PR is this?

What this PR does / why we need it:
In #4481, TLS config loading was changed to load the latest certs when a new client connection is established:

return loadConfig()

This effectively made it possible to rotate certificate without restarting the xds runner.

This PR adds an e2e test that rotates Envoy Gateway/Envoy certificates and verifies that:

  • Clients using rotated certs are able to connect to EG (which picks up the new cert). EG XDS is exposed with LB SVC for convenience.
  • Envoy's SSL Context metrics indicate that a certificate was rotated for the XDS cluster
  • New configuration is programmed successfully after rotation.
  • Envoy is restarted to terminate existing connections to XDS, and programming still works (using the new certificate for the XDS connections).

Also: improve stability of case preservation test by using a converging assertion.

Which issue(s) this PR fixes:

Relates to #4891

Release Notes: No

Copy link

codecov bot commented Dec 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 66.76%. Comparing base (8dbe6e0) to head (f4bcf7f).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4944      +/-   ##
==========================================
- Coverage   66.77%   66.76%   -0.02%     
==========================================
  Files         209      209              
  Lines       32383    32383              
==========================================
- Hits        21625    21619       -6     
- Misses       9458     9463       +5     
- Partials     1300     1301       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@guydc guydc force-pushed the e2e-eg-cert-reload branch 2 times, most recently from d2ec736 to f98a4f6 Compare December 19, 2024 18:28
guydc added 4 commits January 8, 2025 11:44
Signed-off-by: Guy Daich <[email protected]>
Signed-off-by: Guy Daich <[email protected]>
Signed-off-by: Guy Daich <[email protected]>
@guydc guydc force-pushed the e2e-eg-cert-reload branch from f948654 to aac6ffb Compare January 8, 2025 17:45
@guydc guydc force-pushed the e2e-eg-cert-reload branch from 628e124 to 686eff9 Compare January 9, 2025 17:48
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.

1 participant