PVC
Definition
pvcs:
mypvc:
mounts:
application: /pvc-data
spec:
resources:
requests:
storage: 10Gi
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
annotations: {}
labels:
app.kubernetes.io/component: cicd-sample
app.kubernetes.io/instance: docs
app.kubernetes.io/managed-by: helm
app.kubernetes.io/name: cicd-sample
app.kubernetes.io/part-of: cicd
app.kubernetes.io/version: 1.0.0
exordis/application: cicd-sample
exordis/application-instance: docs
exordis/application-type: service
exordis/environment: test
exordis/product: Some Product
exordis/subsystem: cicd
helm.sh/chart: cicd-subsystem-application-0.1.0
name: cicd-sample-docs-mypvc
namespace: cicd-test
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 10Gi
enabled
-
if set to false pvc is excluded from rendering
default: true
namespace
-
pvc namespace
default: subsystem namespace generated by convention
labels
-
list of labels to add to secret in addition to common labels
default: empty dict
annotations
-
list of annotations to add to secret in addition to common labels
default: empty dict
mounts
-
Defines list of containers to have volume mounts for the
pvc
.key
- container id-
For main workload for application container to be referenced as
application
, others with id fromValues.sidecars
orValues.initContainers
.Batch workloads should be referenced as
[workload collection].[workload id].[container id]
e.gcronjobs.cleanup.main
value
- mount path
Validations
- pvc
id
is unique
Overrides
metadata.name
-
name
is generated from id by convention
Manifests Generation
- common labels are added to metadata
- Persistent Volume Claim manifest is generated for each pvc.
- Volumes are added to parent workload of containers referenced on
mounts
. - Volume mounts are added to containers referenced on
mounts
.