GoogleContainerTools/skaffold

PVC get deleted on clean up (when bound by a Deployment)

开放

#4,366 创建于 2020年6月21日

 (15 条评论) (14 个反应) (0 位负责人)Go (1,416 个派生)batch import
area/cleanuparea/deployhelp wantedkind/feature-requestpriority/p2

仓库指标

星标
 (12,822 个星标)
PR 合并指标
 (平均合并 3天 6小时) (30 天内合并 16 个 PR)

描述

I've used minio as part of a release in Skaffold (sub-chart). link

The helm value of the minio: persistence.enabled is set to true, and a PVC is created for its data. However the PVC get terminated and data is lost when ctrl-c is pressed on Skaffold run. I don't think Skaffold should ever cleanup and delete PVCs.

I can see Skaffold add a clean up label to it, so probably related:

Name:          minio
Namespace:     default
StorageClass:  hostpath
Status:        Bound
Volume:        pvc-4c8b7fd6-c4b9-4281-8984-91064e6ff1ab
Labels:        app=minio
               app.kubernetes.io/managed-by=skaffold-v1.11.0
               chart=minio-5.0.30
               heritage=Helm
               release=file-storage
               skaffold.dev/builder=local
               skaffold.dev/cleanup=true
               skaffold.dev/deployer=helm
               skaffold.dev/docker-api-version=1.40
               skaffold.dev/run-id=1376e569-933e-4669-99e8-42901e3a7e81
               skaffold.dev/tag-policy=git-commit
               skaffold.dev/tail=true
Annotations:   pv.kubernetes.io/bind-completed: yes
               pv.kubernetes.io/bound-by-controller: yes
               volume.beta.kubernetes.io/storage-provisioner: docker.io/hostpath
Finalizers:    [kubernetes.io/pvc-protection]
Capacity:      5Gi
Access Modes:  RWO
VolumeMode:    Filesystem
Mounted By:    minio-678684b4d6-l4dgc

贡献者指南