Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Commit

Permalink
Add AKS-ACR SP HostPath mount to helm chart.
Browse files Browse the repository at this point in the history
  • Loading branch information
ellieayla committed Feb 8, 2019
1 parent df5ca66 commit 0ce0668
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions chart/flux/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,8 @@ The following tables lists the configurable parameters of the Weave Flux chart a
| `registry.ecr.region` | Restrict ECR scanning to these AWS regions; if empty, only the cluster's region will be scanned | `None`
| `registry.ecr.includeId` | Restrict ECR scanning to these AWS account IDs; if empty, all account IDs that aren't excluded may be scanned | `None`
| `registry.ecr.excludeId` | Do not scan ECR for images in these AWS account IDs; the default is to exclude the EKS system account | `602401143452`
| `registry.acr.enabled` | Mount `azure.json` via HostPath into the Flux Pod, enabling Flux to use AKS's service principal for ACR authentication | `false`
| `registry.acr.hostPath` | Alternative location of `azure.json` on the host | `/etc/kubernetes/azure.json`
| `memcached.verbose` | Enable request logging in memcached | `false`
| `memcached.maxItemSize` | Maximum size for one item | `1m`
| `memcached.maxMemory` | Maximum memory to use, in megabytes | `64`
Expand Down
11 changes: 11 additions & 0 deletions chart/flux/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ spec:
- name: git-keygen
emptyDir:
medium: Memory
{{- if .Values.registry.acr.enabled }}
- name: acr-credentials
hostPath:
path: "{{ .Values.registry.acr.mountPath }}"
type: ""
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
Expand All @@ -66,6 +72,11 @@ spec:
readOnly: true
- name: git-keygen
mountPath: /var/fluxd/keygen
{{- if .Values.registry.acr.enabled }}
- name: acr-credentials
mountPath: /etc/kubernetes/azure.json
readOnly: true
{{- end }}
env:
- name: KUBECONFIG
value: /root/.kubectl/config
Expand Down
4 changes: 4 additions & 0 deletions chart/flux/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,10 @@ registry:
region:
includeId:
excludeId:
# Azure ACR settings
acr:
enabled: false
hostPath: /etc/kubernetes/azure.json

memcached:
repository: memcached
Expand Down

0 comments on commit 0ce0668

Please sign in to comment.