From d99aa12eca0077104573d2e27826649f3b70cd22 Mon Sep 17 00:00:00 2001 From: Ruixian Song Date: Tue, 2 Aug 2022 15:28:37 -0700 Subject: [PATCH] Change API code for CustomResponseHeaders --- pkg/apis/backendconfig/v1/types.go | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/pkg/apis/backendconfig/v1/types.go b/pkg/apis/backendconfig/v1/types.go index 8957dc3ac7..74a6ab7168 100644 --- a/pkg/apis/backendconfig/v1/types.go +++ b/pkg/apis/backendconfig/v1/types.go @@ -36,14 +36,15 @@ type BackendConfig struct { // BackendConfigSpec is the spec for a BackendConfig resource // +k8s:openapi-gen=true type BackendConfigSpec struct { - Iap *IAPConfig `json:"iap,omitempty"` - Cdn *CDNConfig `json:"cdn,omitempty"` - SecurityPolicy *SecurityPolicyConfig `json:"securityPolicy,omitempty"` - TimeoutSec *int64 `json:"timeoutSec,omitempty"` - ConnectionDraining *ConnectionDrainingConfig `json:"connectionDraining,omitempty"` - SessionAffinity *SessionAffinityConfig `json:"sessionAffinity,omitempty"` - CustomRequestHeaders *CustomRequestHeadersConfig `json:"customRequestHeaders,omitempty"` - HealthCheck *HealthCheckConfig `json:"healthCheck,omitempty"` + Iap *IAPConfig `json:"iap,omitempty"` + Cdn *CDNConfig `json:"cdn,omitempty"` + SecurityPolicy *SecurityPolicyConfig `json:"securityPolicy,omitempty"` + TimeoutSec *int64 `json:"timeoutSec,omitempty"` + ConnectionDraining *ConnectionDrainingConfig `json:"connectionDraining,omitempty"` + SessionAffinity *SessionAffinityConfig `json:"sessionAffinity,omitempty"` + CustomRequestHeaders *CustomRequestHeadersConfig `json:"customRequestHeaders,omitempty"` + CustomResponseHeaders *CustomResponseHeadersConfig `json:"customResponseHeaders,omitempty"` + HealthCheck *HealthCheckConfig `json:"healthCheck,omitempty"` // Logging specifies the configuration for access logs. Logging *LogConfig `json:"logging,omitempty"` } @@ -197,6 +198,12 @@ type CustomRequestHeadersConfig struct { Headers []string `json:"headers,omitempty"` } +// CustomResponseHeadersConfig contains configuration for custom response headers +// +k8s:openapi-gen=true +type CustomResponseHeadersConfig struct { + Headers []string `json:"headers,omitempty"` +} + // HealthCheckConfig contains configuration for the health check. // +k8s:openapi-gen=true type HealthCheckConfig struct {