Skip to content

Commit

Permalink
feat(vector): Add extraVolumes and extraVolumeMounts parameters (#74)
Browse files Browse the repository at this point in the history
Signed-off-by: Spencer Gilbert <[email protected]>
  • Loading branch information
spencergilbert authored Oct 1, 2021
1 parent 0555fb0 commit 895354f
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 0 deletions.
2 changes: 2 additions & 0 deletions charts/vector/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ helm install --name <RELEASE_NAME> \
| dnsPolicy | string | `"ClusterFirst"` | Specify DNS policy for Vector Pods |
| env | list | `[]` | Set environment variables in Vector containers |
| existingConfigMaps | list | `[]` | List of existing ConfigMaps for Vector's configuration instead of creating a new one, if used requires dataDir to be set. Additionally, containerPorts and service.ports should be specified based on your supplied configuration |
| extraVolumeMounts | list | `[]` | Additional Volume to mount into Vector Containers |
| extraVolumes | list | `[]` | Additional Volumes to use with Vector Pods |
| fullnameOverride | string | `""` | Override the full qualified app name |
| image.pullPolicy | string | `"IfNotPresent"` | Vector image pullPolicy |
| image.pullSecrets | list | `[]` | Agent repository pullSecret (ex: specify docker registry credentials) |
Expand Down
15 changes: 15 additions & 0 deletions charts/vector/ci/extra-volume-values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Including additional Volumes
## Values file for testing adding additional Volumes to Vector Pods.
extraVolumes:
- name: podinfo
downwardAPI:
items:
- path: "labels"
fieldRef:
fieldPath: metadata.labels
- path: "annotations"
fieldRef:
fieldPath: metadata.annotations
extraVolumeMounts:
- name: podinfo
mountPath: "/etc/podinfo"
6 changes: 6 additions & 0 deletions charts/vector/templates/_pod.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,9 @@ containers:
mountPath: "/host/sys"
readOnly: true
{{- end }}
{{- with .Values.extraVolumeMounts }}
{{- toYaml . | nindent 6 }}
{{- end }}
terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }}
{{- with .Values.nodeSelector }}
nodeSelector:
Expand Down Expand Up @@ -183,4 +186,7 @@ volumes:
hostPath:
path: "/sys"
{{- end }}
{{- with .Values.extraVolumes }}
{{- toYaml . | nindent 2 }}
{{- end }}
{{- end }}
6 changes: 6 additions & 0 deletions charts/vector/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,12 @@ dataDir: ""
## Ref: https://vector.dev/docs/reference/configuration/
customConfig: {}

# extraVolumes -- Additional Volumes to use with Vector Pods
extraVolumes: []

# extraVolumeMounts -- Additional Volume to mount into Vector Containers
extraVolumeMounts: []

## Configuration for Vector's data persistence
persistence:
# persistence.enabled -- If true, create and use PersistentVolumeClaims
Expand Down

0 comments on commit 895354f

Please sign in to comment.