-
Notifications
You must be signed in to change notification settings - Fork 134
Swiftless OpenStack #441
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
Swiftless OpenStack #441
Conversation
|
/test e2e-openstack |
|
/test e2e-openstack |
1 similar comment
|
/test e2e-openstack |
|
/retest |
dmage
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to write a test this change?
pkg/operator/bootstrap.go
Outdated
| claim, err := c.clients.Core.PersistentVolumeClaims(defaults.ImageRegistryOperatorNamespace).Get(claimName, metav1.GetOptions{}) | ||
| if err == nil { | ||
| if !pvc.PVCIsCreatedByOperator(claim) { | ||
| err = fmt.Errorf("could not create this PVC, it already exists and is not owned by the operator") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need this check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep, removed it
pkg/storage/pvc/pvc.go
Outdated
| PVCOwnerAnnotation = "imageregistry.openshift.io" | ||
|
|
||
| // PVCImageRegistryName is the defailt name of the claim provisioned for PVC backend | ||
| PVCImageRegistryName = defaults.ImageRegistryName + "-storage" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's move this constant to defaults. And in that package it's better to have something like PVCImageRegistryName = "image-registry-storage" to make it greppable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makes sense! done
pkg/storage/pvc/pvc.go
Outdated
| pvcOwnerAnnotation = "imageregistry.openshift.io" | ||
| PVCOwnerAnnotation = "imageregistry.openshift.io" | ||
|
|
||
| // PVCImageRegistryName is the defailt name of the claim provisioned for PVC backend |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-defailt
+default
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done :)
This patch adds a function that checks if Swift service is enabled. To do so it reuses the existing getSwiftClient function, that has this check.
This commit allows to use RWO PVC backend for OpenStack if Swift is not available.
|
@dmage I added a unit test to check that the |
|
/test e2e-openstack |
|
/retest |
|
/test e2e-aws-upgrade |
1 similar comment
|
/test e2e-aws-upgrade |
|
/lgtm Holding until we solve problems with upgrades |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dmage, Fedosin The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/test e2e-aws-upgrade |
1 similar comment
|
/test e2e-aws-upgrade |
|
e2e-aws-upgrade is green! |
|
/hold cancel |
This PR allows to use RWO PVC backend for OpenStack if Swift service is not available.