Skip to content

fix: cephadm_bootstrap should check /etc/ceph for idempotency#41

Open
dotoleeoak wants to merge 2 commits into
ceph:mainfrom
dotoleeoak:main
Open

fix: cephadm_bootstrap should check /etc/ceph for idempotency#41
dotoleeoak wants to merge 2 commits into
ceph:mainfrom
dotoleeoak:main

Conversation

@dotoleeoak

Copy link
Copy Markdown

Module cephadm_bootstrap should check if Ceph config already exists for idempotency check.
The module has been checking '/var/lib/ceph', while the default config dir is '/etc/ceph'.
The bug introduced from upstream: ceph/cephadm-ansible@2645b6a

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Fixes cephadm_bootstrap idempotency detection by checking for existing Ceph config artifacts under the default config directory (/etc/ceph) instead of /var/lib/ceph, aligning the module behavior with Ceph’s default configuration location.

Changes:

  • Update idempotency path checks in cephadm_bootstrap to use /etc/ceph.
  • Add unit tests covering idempotent skip behavior and allow_overwrite behavior.
  • Add a changelog fragment describing the bugfix.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
plugins/modules/cephadm_bootstrap.py Switch idempotency “already deployed” checks from /var/lib/ceph to /etc/ceph.
tests/unit/modules/test_cephadm_bootstrap.py Add unit tests validating the updated idempotency behavior and overwrite override.
changelogs/fragments/cephadm_bootstrap_idempotency.yaml Document the idempotency path correction (contains a small typo).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread changelogs/fragments/cephadm_bootstrap_idempotency.yaml Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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.

2 participants