openshift-evangelists / oc-cluster-wrapper

oc cluster up bash wrapper
Apache License 2.0
144 stars 72 forks source link

Should not use Recycle where path supplied for volume, use Retain instead. #6

Closed GrahamDumpleton closed 8 years ago

GrahamDumpleton commented 8 years ago

When using Recycle the oc cluster up instance will attempt to remove files in the directory it is given when the pvc is deleted. If a file in the volume is read only, then it will actually fail and give up, but is still attempting to remove stuff and if it can it will. When it does fail, it still allows the volume to be reused even though not empty.

Thus when supplying a path for volumes, be it with create-volume or create-shared-volume, the persistentVolumeReclaimPolicy should be set to Retain to avoid someone deleting all there files because they gave a path to stuff in their home directory or elsewhere.

Need perhaps a way of the manually making that volume reusable again.

jorgemoralespou commented 8 years ago

Yes. I thought it was retain. I'll fix this.

El 23 sept. 2016 9:55, "Graham Dumpleton" notifications@github.com escribió:

When using Recycle the oc cluster up instance will attempt to remove files in the directory it is given when the pvc is deleted. If a file in the volume is read only, then it will actually fail and give up, but is still attempting to remove stuff and if it can it will. When it does fail, it still allows the volume to be reused even though not empty.

Thus when supplying a path for volumes, be it with create-volume or create-shared-volume, the persistentVolumeReclaimPolicy should be set to Retain to avoid someone deleting all there files because they gave a path to stuff in their home directory or elsewhere.

Need perhaps a way of the manually making that volume reusable again.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/jorgemoralespou/oc-cluster-wrapper/issues/6, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEyDrYuFJf-3iyQn629fyp1J188NdJJks5qs4XrgaJpZM4KEtCa .

jorgemoralespou commented 8 years ago

@GrahamDumpleton in the docs I created initially, I was thinking on doing a recycle-volume, but this is food for thought