| giolekva | 716efb9 | 2022-05-07 23:08:58 +0400 | [diff] [blame] | 1 | apiVersion: batch/v1 |
| 2 | kind: Job |
| 3 | metadata: |
| 4 | name: fluxcd-bootstrap |
| 5 | namespace: {{ .Release.Namespace }} |
| 6 | spec: |
| 7 | template: |
| 8 | spec: |
| 9 | volumes: |
| 10 | - name: access-keys |
| 11 | configMap: |
| 12 | name: access-keys |
| 13 | - name: known-hosts |
| 14 | configMap: |
| 15 | name: known-hosts |
| 16 | containers: |
| 17 | - name: fluxcd |
| 18 | image: {{ .Values.image.repository }}:{{ .Values.image.tag }} |
| 19 | imagePullPolicy: {{ .Values.image.pullPolicy }} |
| 20 | volumeMounts: |
| 21 | - name: access-keys |
| 22 | mountPath: /access-keys |
| 23 | - name: known-hosts |
| 24 | mountPath: /.ssh |
| 25 | env: |
| 26 | - name: SSH_KNOWN_HOSTS |
| 27 | value: /.ssh/known_hosts |
| 28 | command: ["./flux", "bootstrap", "git", |
| 29 | "--namespace={{ .Values.installationNamespace}}", |
| 30 | "--url={{ .Values.repositoryAddress }}", |
| 31 | "--branch={{ .Values.repository.branch }}", |
| 32 | "--path={{ .Values.repository.path }}", |
| 33 | "--private-key-file=/access-keys/private.key", |
| 34 | "--ssh-key-algorithm=ed25519", |
| giolekva | 9eacb1a | 2022-05-21 13:57:19 +0400 | [diff] [blame^] | 35 | "--silent", |
| 36 | "--watch-all-namespaces", |
| giolekva | 716efb9 | 2022-05-07 23:08:58 +0400 | [diff] [blame] | 37 | "--verbose"] |
| 38 | restartPolicy: Never |