Created
February 2, 2023 16:31
-
-
Save bleggett/aae403d754724d7ed99bdc3751fe818f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# TODO destination rules need to be created for any SPIFFE IDs that don't follow the | |
# format that Istio expects (ns/NAMESPACE/sa/TARGET_POD_SVC_ACCOUNT) | |
# because ATM Istio defaults to clientside SAN checks that assume that SPIFFE ID format | |
# and this is not currently configurable | |
# | |
# Additionally, since DestinationRules override Istio's "default automTLS" settings, we need `mode: ISTIO_MUTUAL` | |
# in each DestRule to tell Istio that even though we have a custom destination config, we still want mTLS. | |
{{- range .Values.spireIdentities }} | |
--- | |
apiVersion: networking.istio.io/v1beta1 | |
kind: DestinationRule | |
metadata: | |
name: {{ .serviceName }}-custom-spire-destrule | |
spec: | |
host: {{ .serviceName }} | |
trafficPolicy: | |
tls: | |
mode: ISTIO_MUTUAL | |
subjectAltNames: | |
- spiffe://example.org/ns/{{ $.Release.Namespace }}/sa/{{ .serviceName }}/wl/foo | |
{{- end }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment