* Set secondary GID of user on import and upload pods to be 107 (qemu) for kubevirt content type.
Signed-off-by: Alexander Wels <awels@redhat.com>
* Fix broken unit tests on upload.
Signed-off-by: Alexander Wels <awels@redhat.com>
* Add import and clone test.
Signed-off-by: Alexander Wels <awels@redhat.com>
If we create a temporary pod in the namespace which has
resource quota, `must specify quota` error occurs. Fix to
create temporary pod with default resource quota.
Co-authored-by: hyoung-90 <ssarang520@gmail.com>
Co-authored-by: Woohyung Han <woohhan@gmail.com>
Signed-off-by: anencore94 <anencore94@kaist.ac.kr>
Co-authored-by: anencore94 <37469330+anencore94@users.noreply.github.com>
Co-authored-by: hyoung-90 <58063867+hyoung-90@users.noreply.github.com>
* unique cert per clone source pod
Signed-off-by: Michael Henriksen <mhenriks@redhat.com>
* upload controller shouldn't cache certs
Signed-off-by: Michael Henriksen <mhenriks@redhat.com>
* fix test variable names
Signed-off-by: Michael Henriksen <mhenriks@redhat.com>
Related to issue #525, we have a similar situation when using PVCs
without DataVolumes. The user requests a PVC with CDI Importer
annotations, if the Importer POD is in a fail/retry loop and the user
requests deletion of the PVC the PVC will be stuck in terminating
waiting for the user to forcibly delete the running Import POD.
This PR adds a check for PVC delete in the import controller and
will delete the POD explicitly if it sees a PVC delete request. This
will also be picked up for Import DataVolumes, so we can remove the
extra checks that were previously added in the DV controller.
fixes#649fixes#525
This patch does two things:
1. We modify the restar policy from never to "OnFailure" for the
Importer (we already did this for Upload, and we don't want to do it yet
for the Clone pods)
2. Upon succesful completion delete our worker pods
We're not doing this on failed pods right now because in general an
admin will likely want to inspect the pod to see why it failed.
The first question someone will likely ask is "well what about a node
failure", well in the case of a node failure for CDI we have a bigger
outstanding issue remaining to figure out how to deal with volume
connections. We can't just simply reschedule the job.