gateway icon indicating copy to clipboard operation
gateway copied to clipboard

feat: Add EnvoyProxyTemplate for global Envoy Proxy defaults

Open mgs255 opened this issue 1 month ago • 1 comments

Add EnvoyProxyTemplate for global Envoy Proxy defaults

Introduce EnvoyProxyTemplate in EnvoyGateway provider configuration to define default settings for all Envoy Proxy deployments. Individual EnvoyProxy resource settings take precedence over these template defaults.

This change includes:

  • Add EnvoyProxyTemplate field to EnvoyGatewayKubernetesProvider API
  • Implement merge functions for combining template defaults with more specific configurations
    • Container specs (image, env vars, resources, volume mounts)
    • Pod specs (annotations, labels, volumes, tolerations, affinity)
  • Extend helm chart to support configuring default Envoy Proxy image settings via new envoyProxyTemplate object.
  • Add unit tests for merge logic

Fixes: https://github.com/envoyproxy/gateway/issues/4764

mgs255 avatar Dec 08 '25 10:12 mgs255

Codecov Report

:x: Patch coverage is 75.00000% with 13 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 72.35%. Comparing base (76d4076) to head (c198efe). :warning: Report is 6 commits behind head on main.

Files with missing lines Patch % Lines
internal/gatewayapi/contexts.go 53.84% 5 Missing and 1 partial :warning:
internal/gatewayapi/envoyproxy_merge.go 83.33% 2 Missing and 2 partials :warning:
internal/gatewayapi/runner/runner.go 0.00% 2 Missing :warning:
api/v1alpha1/envoygateway_helpers.go 80.00% 1 Missing :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7698      +/-   ##
==========================================
- Coverage   72.40%   72.35%   -0.06%     
==========================================
  Files         234      235       +1     
  Lines       34562    34609      +47     
==========================================
+ Hits        25026    25041      +15     
- Misses       7748     7772      +24     
- Partials     1788     1796       +8     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Dec 10 '25 18:12 codecov[bot]