Skip to content
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

Implement tests for ceph-mon's rotate-key action #1195

Merged
merged 16 commits into from
Apr 22, 2024

Conversation

lmlg
Copy link
Contributor

@lmlg lmlg commented Apr 5, 2024

This PR implements tests for the ceph-mon charm's action 'rotate-key'. For now, the charm only supports key rotation for managers, but more entities will be added. This PR will be used to test those new entities as well.

lmlg added 2 commits April 5, 2024 18:05
This PR implements tests for the ceph-mon charm's action 'rotate-key'.
For now, the charm only supports key rotation for managers, but
more entities will be added. This PR will be used to test those
new entities as well.
openstack-mirroring pushed a commit to openstack/charm-ceph-mon that referenced this pull request Apr 9, 2024
This patchset implements key rotation for managers only. The user
can specified either the full entity name (i.e: 'mgr.XXXX') or
simply 'mgr', which stands for the local manager.

After the entity's directory is located, a new pending key is
generated, the keyring file is mutated to include the new key and
then replaced in situ. Lastly, the manager service is restarted.

Note that Ceph only has one active manager at a certain point,
so it only makes sense to call this action on _every_ mon unit.

Change-Id: Ie24b3f30922fa5be6641e37635440891614539d5
func-test-pr: openstack-charmers/zaza-openstack-tests#1195
openstack-mirroring pushed a commit to openstack/openstack that referenced this pull request Apr 9, 2024
* Update charm-ceph-mon from branch 'master'
  to 05725042300c02ef4f7490e3e1a34b84be8ddcbe
  - Implement the 'rotate-key' action for managers
    
    This patchset implements key rotation for managers only. The user
    can specified either the full entity name (i.e: 'mgr.XXXX') or
    simply 'mgr', which stands for the local manager.
    
    After the entity's directory is located, a new pending key is
    generated, the keyring file is mutated to include the new key and
    then replaced in situ. Lastly, the manager service is restarted.
    
    Note that Ceph only has one active manager at a certain point,
    so it only makes sense to call this action on _every_ mon unit.
    
    Change-Id: Ie24b3f30922fa5be6641e37635440891614539d5
    func-test-pr: openstack-charmers/zaza-openstack-tests#1195
Copy link
Contributor

@sabaini sabaini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quick notes on the tests

zaza/openstack/charm_tests/ceph/tests.py Outdated Show resolved Hide resolved
zaza/openstack/charm_tests/ceph/tests.py Show resolved Hide resolved
Copy link
Contributor

@sabaini sabaini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm as-is 👍
The title says [WIP] is this still accurate?

@lmlg
Copy link
Contributor Author

lmlg commented Apr 12, 2024

lgtm as-is 👍 The title says [WIP] is this still accurate?

yes. the patchset for OSDs isn't ready yet, and I want this PR to be run for its functional tests.

openstack-mirroring pushed a commit to openstack/charm-ceph-mon that referenced this pull request Apr 12, 2024
This patchset implements the needed functionality on the ceph-mon
charm to rotate the key of a specified RadosGW daemon.

func-test-pr: openstack-charmers/zaza-openstack-tests#1195
Change-Id: I6dbbf6ca1292a34f5d3b4ff8f2966c8b77f53f48
openstack-mirroring pushed a commit to openstack/openstack that referenced this pull request Apr 12, 2024
* Update charm-ceph-mon from branch 'master'
  to 446d17f625b5c750b273afd84b9ebd628a48fc9c
  - Implement key rotation for RadosGW daemons
    
    This patchset implements the needed functionality on the ceph-mon
    charm to rotate the key of a specified RadosGW daemon.
    
    func-test-pr: openstack-charmers/zaza-openstack-tests#1195
    Change-Id: I6dbbf6ca1292a34f5d3b4ff8f2966c8b77f53f48
openstack-mirroring pushed a commit to openstack/charm-ceph-radosgw that referenced this pull request Apr 18, 2024
This patchset implements key rotation in the ceph-radosgw charm,
by replacing the keyring file if it exists and the ceph-mon
relation reports a new key.

Change-Id: I447b5f827e39118e7dbd430b1c63b3ec4ea3e176
func-test-pr: openstack-charmers/zaza-openstack-tests#1195
openstack-mirroring pushed a commit to openstack/openstack that referenced this pull request Apr 18, 2024
* Update charm-ceph-radosgw from branch 'master'
  to 940be7fdfc6729ffeb7dd37d50943a2aeecdcda6
  - Implement key rotation on the ceph-radosgw charm
    
    This patchset implements key rotation in the ceph-radosgw charm,
    by replacing the keyring file if it exists and the ceph-mon
    relation reports a new key.
    
    Change-Id: I447b5f827e39118e7dbd430b1c63b3ec4ea3e176
    func-test-pr: openstack-charmers/zaza-openstack-tests#1195
@lmlg lmlg changed the title [WIP] Implement tests for ceph-mon's rotate-key action Implement tests for ceph-mon's rotate-key action Apr 19, 2024
@lmlg
Copy link
Contributor Author

lmlg commented Apr 19, 2024

The PR is ready for merge now. The mgr and RGW pieces have been run with this PR already.

@lmlg
Copy link
Contributor Author

lmlg commented Apr 22, 2024

@sabaini sabaini merged commit 2e0beac into openstack-charmers:master Apr 22, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants