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

refactor: remove explicit test case definition for xds translator test #3230

Merged
merged 4 commits into from
Apr 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@ http:
mergeSlashes: true
escapedSlashesAction: UnescapeAndRedirect
tls:
- name: first-listener
# byte slice representation of "cert-data"
serverCertificate: [99, 101, 114, 116, 45, 100, 97, 116, 97]
# byte slice representation of "key-data"
privateKey: [107, 101, 121, 45, 100, 97, 116, 97]
certificates:
- name: first-listener
# byte slice representation of "cert-data"
serverCertificate: [99, 101, 114, 116, 45, 100, 97, 116, 97]
# byte slice representation of "key-data"
privateKey: [107, 101, 121, 45, 100, 97, 116, 97]
routes:
- name: "first-route"
hostname: "*"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
- name: secret-1
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
- name: secret-2
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
- commonLbConfig:
- circuitBreakers:
thresholds:
- maxRetries: 1024
commonLbConfig:
localityWeightedLbConfig: {}
connectTimeout: 10s
dnsLookupFamily: V4_ONLY
Expand All @@ -12,34 +15,3 @@
outlierDetection: {}
perConnectionBufferLimitBytes: 32768
type: EDS
- commonLbConfig:
localityWeightedLbConfig: {}
connectTimeout: 10s
dnsLookupFamily: V4_ONLY
dnsRefreshRate: 30s
lbPolicy: LEAST_REQUEST
loadAssignment:
clusterName: localhost_443
endpoints:
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: localhost
portValue: 443
loadBalancingWeight: 1
loadBalancingWeight: 1
locality: {}
name: localhost_443
outlierDetection: {}
perConnectionBufferLimitBytes: 32768
respectDnsTtl: true
transportSocket:
name: envoy.transport_sockets.tls
typedConfig:
'@type': type.googleapis.com/envoy.extensions.transport_sockets.tls.v3.UpstreamTlsContext
commonTlsContext:
validationContext:
trustedCa:
filename: /etc/ssl/certs/ca-certificates.crt
type: STRICT_DNS
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@
portValue: 50000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality: {}
locality:
region: first-route-dest/backend/0
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
socketAddress:
address: 0.0.0.0
portValue: 10080
drainType: MODIFY_ONLY
filterChains:
- filters:
- name: envoy.filters.network.http_connection_manager
Expand All @@ -14,26 +15,6 @@
initialStreamWindowSize: 65536
maxConcurrentStreams: 100
httpFilters:
- name: envoy.filters.http.jwt_authn
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this changing ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

because this test file has been ignored (not explicit defined in test cases) until now, its content is outdated.

typedConfig:
'@type': type.googleapis.com/envoy.extensions.filters.http.jwt_authn.v3.JwtAuthentication
providers:
first-route/example:
audiences:
- foo.com
issuer: https://www.example.com
payloadInMetadata: https://www.example.com
remoteJwks:
asyncFetch: {}
cacheDuration: 300s
httpUri:
cluster: localhost_443
timeout: 5s
uri: https://localhost/jwt/public-key/jwks.json
retryPolicy: {}
requirementMap:
first-route:
providerName: first-route/example
- name: envoy.filters.http.router
typedConfig:
'@type': type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
Expand All @@ -48,8 +29,6 @@
routeConfigName: first-listener
serverHeaderTransformation: PASS_THROUGH
statPrefix: https
upgradeConfigs:
- upgradeType: websocket
useRemoteAddress: true
transportSocket:
name: envoy.transport_sockets.tls
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,5 @@
name: first-route
route:
cluster: first-route-dest
typedPerFilterConfig:
envoy.filters.http.jwt_authn:
'@type': type.googleapis.com/envoy.extensions.filters.http.jwt_authn.v3.PerRouteConfig
requirementName: first-route
upgradeConfigs:
- upgradeType: websocket
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
- genericSecret:
secret:
inlineBytes: Y2xpZW50MTpzZWNyZXQK
name: oauth2/client_secret/securitypolicy/default/policy-for-gateway-2
- genericSecret:
secret:
inlineBytes: ""
name: oauth2/hmac_secret/securitypolicy/default/policy-for-gateway-2
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
- name: secret-1
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
- name: secret-2
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
- name: envoy-gateway-tls-secret-1
tlsCertificate:
certificateChain:
inlineBytes: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUNxRENDQVpBQ0NRREVNZ1lZblFyQ29EQU5CZ2txaGtpRzl3MEJBUXNGQURBV01SUXdFZ1lEVlFRRERBdG0KYjI4dVltRnlMbU52YlRBZUZ3MHlNekF4TURVeE16UXpNalJhRncweU5EQXhNRFV4TXpRek1qUmFNQll4RkRBUwpCZ05WQkFNTUMyWnZieTVpWVhJdVkyOXRNSUlCSWpBTkJna3Foa2lHOXcwQkFRRUZBQU9DQVE4QU1JSUJDZ0tDCkFRRUFuZEh6d21wS2NUSUViamhGZ2RXd1RSTjc1Y3A4b3VsWnhMMUdydlI2SXc3ejdqaTBSNFcvTm85bkdmOU0KWVAyQ1JqaXN6NTFtd3hTeGVCcm9jTGVBK21reGkxK2lEdk5kQytyU0x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change
@@ -0,0 +1,12 @@
- name: secret-1
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
- name: secret-2
tlsCertificate:
certificateChain:
inlineBytes: Y2VydC1kYXRh
privateKey:
inlineBytes: a2V5LWRhdGE=
Loading