Coder Social home page Coder Social logo

phenixblue / volrec Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 0.0 27.22 MB

Kubernetes Volume Reclaim Controller

License: Apache License 2.0

Dockerfile 2.95% Makefile 11.11% Go 85.94%
volrec k8s kubernetes controller kubebuilder core volume reclaim pv pvc

volrec's Introduction

Hi there ๐Ÿ‘‹

volrec's People

Contributors

phenixblue avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

volrec's Issues

Annotate PVC with errors from Controller

Need to add functionality to the controller to update target PVC resources when certain errors occur within the reconciliation.

At a minimum for when an incorrect volume retention policy is specified.

Example:

When labeling a PVC with a retention policy that isn't Retain, Delete, or Recycle the controller logs the following errors:

2021-08-17T20:28:05.659Z	INFO	controllers.PersistentVolumeClaim	Setting reclaim policy to match PVC label	{"pvc": "test2/datadir-crdb1-2", "pv": "pvc-70a047e8-bc55-4ff8-b389-76cd07440f3d", "policy-from-pvc-label": "Dummy", "policy-from-pv": "Delete"}
2021-08-17T20:28:05.663Z	ERROR	controller-runtime.controller	Reconciler error	{"controller": "persistentvolumeclaim", "request": "test2/datadir-crdb1-2", "error": "could not update PV: PersistentVolume \"pvc-70a047e8-bc55-4ff8-b389-76cd07440f3d\" is invalid: spec.persistentVolumeReclaimPolicy: Unsupported value: \"Dummy\": supported values: \"Delete\", \"Recycle\", \"Retain\""}

Information about the error could be added to an annotation on the target PVC resource to provide a feedback mechanism to end-users who probably don't have access to view the volrec controller logs.

Need to provide input validation on policy label

Currently the Volrec controller does not sanitize/guard against arbitrary values for the reclaim policy label.

Need to make sure we only allow valid values that match to actual supported reclaim policies.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.