Patch every outbound cluster
Match on origin alone to change a field on all outbound clusters, without naming each one.
Configuration
apiVersion: kuma.io/v1alpha1
kind: MeshProxyPatch
metadata:
name: backend-outbound-connect-timeout
namespace: kong-mesh-demo
labels:
kuma.io/mesh: default
spec:
targetRef:
kind: Dataplane
labels:
app: backend
default:
appendModifications:
- cluster:
operation: Patch
match:
origin: outbound
value: 'connectTimeout: 10s 'Copied!
type: MeshProxyPatch
name: backend-outbound-connect-timeout
mesh: default
spec:
targetRef:
kind: Dataplane
labels:
app: backend
default:
appendModifications:
- cluster:
operation: Patch
match:
origin: outbound
value: 'connectTimeout: 10s 'Copied!
Adjust konnect_mesh_control_plane.my_meshcontrolplane.id and konnect_mesh.my_mesh.name according to your current configuration.
resource "konnect_mesh_proxy_patch" "backend_outbound_connect_timeout" {
provider = konnect-beta
type = "MeshProxyPatch"
name = "backend-outbound-connect-timeout"
spec = {
target_ref = {
kind = "Dataplane"
labels = {
app = "backend"
}
}
default = {
append_modifications = [
{
cluster = {
operation = "Patch"
match = {
origin = "outbound"
}
value = "connectTimeout: 10s "
}
}
]
}
}
labels = {
"kuma.io/mesh" = konnect_mesh.my_mesh.name
}
cp_id = konnect_mesh_control_plane.my_meshcontrolplane.id
mesh = konnect_mesh.my_mesh.name
}
Copied!