okteto icon indicating copy to clipboard operation
okteto copied to clipboard

Different PV default sizes between cloud/staging and others

Open AgustinRamiroDiaz opened this issue 1 year ago • 3 comments

Proposed changes

Fixes #3045

  • Handles default PV sizes depending on the context
  • Handle error when updating PVC

Additional context

We had a conversation with @pchico83 about the UX for the migration from 2Gi to 5Gi and we settled for only showing a warning if the update failed due to the upscaling. We won't try to recreate the volume because we'd need to delete the pod that has the volume attached, which takes a lot more time.

AgustinRamiroDiaz avatar Sep 13 '22 15:09 AgustinRamiroDiaz

Thank you for your contribution. unfortunately, one or more of your commits are missing the required "Signed-off-by:" statement. Signing off is part of the Developer Certificate of Origin (DCO) which is used by this project.

Read the DCO and project contributing guide carefully, and amend your commits using the git CLI. Note that this does not require any cryptography, keys or special steps to be taken.

:bulb: Shall we fix this?

This will only take a few moments.

First, clone your fork and checkout this branch using the git CLI.

Next, set up your real name and email address:

git config --global user.name "Your Full Name" git config --global user.email "[email protected]"

Finally, run one of these commands to add the "Signed-off-by" line to your commits.

If you only have one commit so far then run: git commit --amend --signoff and then git push --force. If you have multiple commits, watch this video.

Check that the message has been added properly by running "git log".

derek[bot] avatar Sep 13 '22 15:09 derek[bot]

@pchico83 As discussed, I handled the error when updating dev volumes. Currently I added only the catch for errors like "persistentvolumeclaims \"%s\" is forbidden: only dynamically provisioned pvc can be resized and the storageclass that provisions the pvc must support resize"

Should we catch all errors and never fail? We'd still be able to log the error in debug mode

AgustinRamiroDiaz avatar Sep 14 '22 15:09 AgustinRamiroDiaz

@pchico83 As discussed, I handled the error when updating dev volumes. Currently I added only the catch for errors like "persistentvolumeclaims \"%s\" is forbidden: only dynamically provisioned pvc can be resized and the storageclass that provisions the pvc must support resize"

Should we catch all errors and never fail? We'd still be able to log the error in debug mode

@AgustinRamiroDiaz Let's do it just for resize errors for now

pchico83 avatar Sep 14 '22 15:09 pchico83