-
Notifications
You must be signed in to change notification settings - Fork 78
configure_swift_rgw_post_adopiton #1123
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
base: main
Are you sure you want to change the base?
configure_swift_rgw_post_adopiton #1123
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
Merge Failed. This change or one of its cross-repo dependencies was unable to be automatically merged with the current state of its repository. Please rebase the change and upload a new patchset. |
93e6fb1 to
126c7a1
Compare
|
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/e0ed26b1173e467388f255330793e52d ✔️ noop SUCCESS in 0s |
551faac to
8796750
Compare
|
Testing internally. This log shows that configure_swift_rgw playbook is executed and configured the swift endpoints correctly. |
1e49fb1 to
83fb0e3
Compare
|
Tested again on top of the updated code. |
|
|
||
| - name: Set variables for Ceph RGW configuration | ||
| ansible.builtin.set_fact: | ||
| ceph_keystone_ep: "{{ keystone_url }}" |
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.
I have a question here. You set ceph_keystone_ep: "{{ keystone_url }}" based on the output of the previous task, which clearly addresses the best case scenario.
What happens when keystone_svc_lb_ip.stdout | length > 0 let the above being skipped? In that case keystone_url won't be set and you will fail on L27.
In addition, as per my reading of this code, we make a double facts assignment, which is not efficient:
keystone_url: "{{ keystone_protocol | default('http') }}://{{ keystone_svc_lb_ip.stdout | ansible.utils.ipwrap }}:5000"ceph_keystone_ep: "{{ keystone_url }}"
What if we only set the fact once, and skip it, or fail in case keystone_svc_lb_ip.stdout | length <= 0 ?
Same thing might be applied to swift_password_result.stdout. Because I don't see extra checks I'm wondering if we should avoid setting facts multiple times and instead have a fail if the input is not good.
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.
@fmount good catch, i agree there is a scope for improvement here, i will fix it
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 commit adds support for configuring Swift object storage to use Ceph RGW after adoption is complete. The configuration requires the adopted OpenShift environment to be running with Keystone services available. Changes: - Add configure_swift_rgw.yaml playbook with three phases: 1. Extract Swift password and Keystone endpoint from OpenShift 2. Configure Ceph RGW with Keystone integration settings 3. Configure Swift endpoints to use RGW backend - Add test-configure-object Makefile target to invoke the playbook - Playbook uses variables extracted at runtime from the live OpenShift environment (ceph_keystone_ep, ceph_keystone_swift_pwd, and ceph_rgw_virtual_ips_list) which are passed to the ceph_migrate role
83fb0e3 to
2826c5f
Compare
This commit adds support for configuring Swift object storage to use
Ceph RGW after adoption is complete. The configuration requires the
adopted OpenShift environment to be running with Keystone
services available.
Changes:
Add configure_swift_rgw.yaml playbook with three phases:
Add test-configure-object Makefile target to invoke the playbook
Playbook uses variables extracted at runtime from the live OpenShift
environment (ceph_keystone_ep, ceph_keystone_swift_pwd, and
ceph_rgw_virtual_ips_list) which are passed to the ceph_migrate role