AAP-54538: remove outdated PVC on reinstallation #643
Merged
+12
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Jira Issue: https://issues.redhat.com/browse/AAP-54538
Description
Upgrade works now, but old PVC keeps running and taking resources. We want to remove PVC on upgrade/install if it is still present. The logic is duplicated as on the delete phase.
Testing
Steps to test
Scenarios tested
Production deployment
Note
Adds an upgrade step to delete the legacy Chatbot PVC before deploying the service.
roles/chatbot/tasks/main.yml
, includeupgrade_chatbot.yml
to clean up old PVC before deployment.roles/chatbot/tasks/upgrade_chatbot.yml
removes legacyPersistentVolumeClaim
({{ ansible_operator_meta.name }}-chatbot-pvc
) in{{ ansible_operator_meta.namespace }}
usingkubernetes.core.k8s
withwait: yes
.Written by Cursor Bugbot for commit 2a6dbfe. This will update automatically on new commits. Configure here.