Skip to content

Commit

Permalink
fix template correctly
Browse files Browse the repository at this point in the history
Signed-off-by: Tarun Pothulapati <tarunpothulapati@outlook.com>
  • Loading branch information
Pothulapati committed May 10, 2020
1 parent 3fe342e commit be3d3ea
Show file tree
Hide file tree
Showing 26 changed files with 145 additions and 55 deletions.
2 changes: 1 addition & 1 deletion charts/add-ons/prometheus/templates/prometheus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ spec:
{{ $_ := set .Values.global.proxy.image "Version" .Values.global.linkerdVersion -}}
{{ end -}}
{{ $_ := set .Values.global.proxy "workloadKind" "deployment" -}}
{{ $_ := set .Values.global.proxy "component" ".Values.name" -}}
{{ $_ := set .Values.global.proxy "component" .Values.name -}}
{{ include "linkerd.proxy.validation" .Values.global.proxy -}}
apiVersion: apps/v1
kind: Deployment
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_addon_control-plane.golden
Original file line number Diff line number Diff line change
Expand Up @@ -2577,7 +2577,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -2588,7 +2588,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -2654,6 +2654,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -2725,6 +2727,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_control-plane.golden
Original file line number Diff line number Diff line change
Expand Up @@ -2117,7 +2117,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -2128,7 +2128,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -2194,6 +2194,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -2265,6 +2267,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_controlplane_tracing_output.golden
Original file line number Diff line number Diff line change
Expand Up @@ -3074,7 +3074,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -3085,7 +3085,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -3153,6 +3153,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3230,6 +3232,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_custom_registry.golden
Original file line number Diff line number Diff line change
Expand Up @@ -2957,7 +2957,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -2968,7 +2968,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -3034,6 +3034,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3105,6 +3107,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: my.custom.registry/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_default.golden
Original file line number Diff line number Diff line change
Expand Up @@ -2957,7 +2957,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -2968,7 +2968,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -3034,6 +3034,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3105,6 +3107,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_ha_output.golden
Original file line number Diff line number Diff line change
Expand Up @@ -3213,7 +3213,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -3224,7 +3224,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -3297,6 +3297,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3374,6 +3376,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_ha_with_overrides_output.golden
Original file line number Diff line number Diff line change
Expand Up @@ -3213,7 +3213,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -3224,7 +3224,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -3297,6 +3297,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3374,6 +3376,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 6 additions & 2 deletions cli/cmd/testdata/install_heartbeat_disabled_output.golden
Original file line number Diff line number Diff line change
Expand Up @@ -2868,7 +2868,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -2879,7 +2879,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
beta.kubernetes.io/os: linux
Expand Down Expand Up @@ -2945,6 +2945,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3016,6 +3018,8 @@ spec:
- "2102"
- --inbound-ports-to-ignore
- 4190,4191
- --outbound-ports-to-ignore
- "443"
image: gcr.io/linkerd-io/proxy-init:v1.3.2
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 5 additions & 3 deletions cli/cmd/testdata/install_helm_output.golden
Original file line number Diff line number Diff line change
Expand Up @@ -3002,7 +3002,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -3013,7 +3013,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
null
Expand Down Expand Up @@ -3079,6 +3079,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3142,7 +3144,7 @@ spec:
- --inbound-ports-to-ignore
- 4190,4191,222
- --outbound-ports-to-ignore
- "111"
- 443,111
image: gcr.io/linkerd-io/proxy-init:test-proxy-init-version
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
8 changes: 5 additions & 3 deletions cli/cmd/testdata/install_helm_output_addons.golden
Original file line number Diff line number Diff line change
Expand Up @@ -3474,7 +3474,7 @@ spec:
matchLabels:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
template:
metadata:
annotations:
Expand All @@ -3485,7 +3485,7 @@ spec:
linkerd.io/control-plane-component: prometheus
linkerd.io/control-plane-ns: linkerd
linkerd.io/workload-ns: linkerd
linkerd.io/proxy-deployment: .Values.name
linkerd.io/proxy-deployment: linkerd-prometheus
spec:
nodeSelector:
null
Expand Down Expand Up @@ -3551,6 +3551,8 @@ spec:
fieldPath: metadata.namespace
- name: LINKERD2_PROXY_DESTINATION_CONTEXT
value: ns:$(_pod_ns)
- name: LINKERD2_PROXY_OUTBOUND_ROUTER_CAPACITY
value: "10000"
- name: LINKERD2_PROXY_IDENTITY_DIR
value: /var/run/linkerd/identity/end-entity
- name: LINKERD2_PROXY_IDENTITY_TRUST_ANCHORS
Expand Down Expand Up @@ -3614,7 +3616,7 @@ spec:
- --inbound-ports-to-ignore
- 4190,4191,222
- --outbound-ports-to-ignore
- "111"
- 443,111
image: gcr.io/linkerd-io/proxy-init:test-proxy-init-version
imagePullPolicy: IfNotPresent
name: linkerd-init
Expand Down
Loading

0 comments on commit be3d3ea

Please sign in to comment.