Bump to latest istio (#9356)

* Bump to latest istio

* fix snip

* change templates

* fix sed magic

* fix bug

* add back vwh configmap
This commit is contained in:
John Howard 2021-03-24 16:29:55 -07:00 committed by GitHub
parent 984dbf0e01
commit af97ea5d0a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 67 additions and 13 deletions

View File

@ -182,6 +182,36 @@ and installing needed webhooks, configmaps, and secrets on the remote cluster so
components:
base:
enabled: false
pilot:
enabled: true
k8s:
overlays:
- kind: Deployment
name: istiod
patches:
- path: spec.template.spec.volumes[100]
value: |-
name: config-volume
configMap:
name: istio
- path: spec.template.spec.volumes[100]
value: |-
name: inject-volume
configMap:
name: istio-sidecar-injector
- path: spec.template.spec.containers[0].volumeMounts[100]
value: |-
name: config-volume
mountPath: /etc/istio/config
- path: spec.template.spec.containers[0].volumeMounts[100]
value: |-
name: inject-volume
mountPath: /var/lib/istio/inject
env:
- name: INJECTION_WEBHOOK_CONFIG_NAME
value: ""
- name: VALIDATION_WEBHOOK_CONFIG_NAME
value: ""
ingressGateways:
- name: istio-ingressgateway
enabled: false
@ -193,10 +223,6 @@ and installing needed webhooks, configmaps, and secrets on the remote cluster so
meshID: mesh1
multiCluster:
clusterName: $REMOTE_CLUSTER_NAME
pilot:
env:
INJECTION_WEBHOOK_CONFIG_NAME: ""
VALIDATION_WEBHOOK_CONFIG_NAME: ""
EOF
{{< /text >}}
@ -372,7 +398,7 @@ and installing needed webhooks, configmaps, and secrets on the remote cluster so
istio-leader 0 2m9s
istio-namespace-controller-election 0 2m11s
istio-sidecar-injector 2 2m1s
istio-validation-controller-election 0 2m9s
istio-validation-controller-election 0 2m6s
{{< /text >}}
{{< text bash >}}

View File

@ -90,6 +90,36 @@ spec:
components:
base:
enabled: false
pilot:
enabled: true
k8s:
overlays:
- kind: Deployment
name: istiod
patches:
- path: spec.template.spec.volumes[100]
value: |-
name: config-volume
configMap:
name: istio
- path: spec.template.spec.volumes[100]
value: |-
name: inject-volume
configMap:
name: istio-sidecar-injector
- path: spec.template.spec.containers[0].volumeMounts[100]
value: |-
name: config-volume
mountPath: /etc/istio/config
- path: spec.template.spec.containers[0].volumeMounts[100]
value: |-
name: inject-volume
mountPath: /var/lib/istio/inject
env:
- name: INJECTION_WEBHOOK_CONFIG_NAME
value: ""
- name: VALIDATION_WEBHOOK_CONFIG_NAME
value: ""
ingressGateways:
- name: istio-ingressgateway
enabled: false
@ -101,10 +131,6 @@ spec:
meshID: mesh1
multiCluster:
clusterName: $REMOTE_CLUSTER_NAME
pilot:
env:
INJECTION_WEBHOOK_CONFIG_NAME: ""
VALIDATION_WEBHOOK_CONFIG_NAME: ""
EOF
}
@ -274,7 +300,7 @@ istio-ca-root-cert 1 2m9s
istio-leader 0 2m9s
istio-namespace-controller-election 0 2m11s
istio-sidecar-injector 2 2m1s
istio-validation-controller-election 0 2m9s
istio-validation-controller-election 0 2m6s
ENDSNIP
snip_set_up_the_remote_cluster_6() {

View File

@ -27,10 +27,12 @@ snip_get_external_istiod_iop_modified() {
snip_get_external_istiod_iop
# Update config file: delete CA certificates and meshID, and update pilot vars
# TODO(https://github.com/istio/istio/issues/31690) remove 'env' replace
sed -i \
-e '/proxyMetadata:/,+2d' \
-e '/INJECTION_WEBHOOK_CONFIG_NAME: ""/d' \
-e "s/VALIDATION_WEBHOOK_CONFIG_NAME: \"\"/ISTIOD_CUSTOM_HOST: ${EXTERNAL_ISTIOD_ADDR}/" \
-e '/INJECTION_WEBHOOK_CONFIG_NAME/,+1d' \
-e "/VALIDATION_WEBHOOK_CONFIG_NAME/,+1d" \
-e "s/env:/env: []/g" \
external-istiod.yaml
}
@ -83,7 +85,7 @@ snip_set_up_the_control_plane_in_the_external_cluster_1
snip_set_up_the_control_plane_in_the_external_cluster_2
snip_get_external_istiod_iop_modified
echo y | snip_set_up_the_control_plane_in_the_external_cluster_4
echo y | istioctl install -f external-istiod.yaml --context="${CTX_EXTERNAL_CLUSTER}" --set values.pilot.env.ISTIOD_CUSTOM_HOST="${EXTERNAL_ISTIOD_ADDR}"
_verify_like snip_set_up_the_control_plane_in_the_external_cluster_5 "$snip_set_up_the_control_plane_in_the_external_cluster_5_out"