-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for persistent volume claims in kube files #8497
Add support for persistent volume claims in kube files #8497
Conversation
Replace the simple map of names to paths with a map of names to a struct to allow passing more parameters. Also move the code to parse the volumes to its own file to avoid making the playKubePod() function overly complex. Finally rework the kube volumes test to also be ready to support more volume types. Signed-off-by: Alban Bedel <[email protected]>
In k8s a persistent volume claim (PVC) allow pods to define a volume by referencing the name of a PVC. The PVC basically contains criterias that k8s then use to select which storage source it will use for the volume. Podman only provide one abtracted storage, the named volumes, and create them if they don't exists yet. So this patch simply use a volume with the name of the PVC. Signed-off-by: Alban Bedel <[email protected]>
Thanks @AlbanBedel @haircommander @mheon PTAL |
be05510
to
66944ba
Compare
I just found about |
maybe need rebase? |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: AlbanBedel, baude The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
lgtm |
/lgtm |
This PR add simple support for persistent volume claims (PVC) to kube files by simply using a named volume with the name of the claim. The first commit rework the code for volumes in kube to allow supporting several types and the second one then add the new volume type.
This should solve bug #5788, but it doesn't overlap with PR #8266 which afaict is about creating the volumes and not using them.