I am preparing a library helm-chart and i would like to know the difference between
volumes:
- hostPath:
path: /var/run/datadog/
name: apmsocketpath
vs
volumes:
- name: {{ .Values.app_prefix }}-storage-{{ .Values.instance_name }}
persistentVolumeClaim:
claimName: {{ .Values.app_prefix }}-pv-claim-{{ .Values.instance_name }}
my understanding is volumes declared with hostpath in Deployment are not retained when the Deploymentt is removed unlike PersistentVolume where it can be shared with other services and can be retained. is this correct