]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
19 months agodoc/dev/release-checklist: mark ceph-container changes done 53191/head
Radosław Zarzyński [Tue, 5 Dec 2023 18:07:47 +0000 (19:07 +0100)]
doc/dev/release-checklist: mark ceph-container changes done

Per https://github.com/ceph/ceph-container/pull/2174.

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agoosd, doc: make OSDMap::pending_require_osd_release() aware about squid
Radosław Zarzyński [Tue, 5 Dec 2023 17:38:46 +0000 (18:38 +0100)]
osd, doc: make OSDMap::pending_require_osd_release() aware about squid

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agodoc/dev/release-checklist: enlist OSDMap::pending_require_osd_release()
Radosław Zarzyński [Tue, 5 Dec 2023 17:26:33 +0000 (18:26 +0100)]
doc/dev/release-checklist: enlist OSDMap::pending_require_osd_release()

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agoosd: adding 'reef' to pending_require_osd_release
Philipp Hufnagl [Wed, 22 Nov 2023 11:31:41 +0000 (12:31 +0100)]
osd: adding 'reef' to pending_require_osd_release

It appears adding 'reef' to pending_require_osd_release has been
forgotten. This PR adds it

Signed-off-by: Philipp Hufangl <p.hufnagl@proxmox.com>
(cherry picked from commit e443ef3562f9718b224acb550206497b5fdfe82e)

19 months agorelease-checklists.rst: mark section for ceph-build as complete
Radoslaw Zarzynski [Sun, 27 Aug 2023 08:04:33 +0000 (08:04 +0000)]
release-checklists.rst: mark section for ceph-build as complete

This bases on https://github.com/ceph/ceph-build/pull/2160.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agotest/cli/monmaptool: adjust for the squid monmap features
Radoslaw Zarzynski [Fri, 25 Aug 2023 14:17:59 +0000 (14:17 +0000)]
test/cli/monmaptool: adjust for the squid monmap features

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoqa: qa/suites/rados/upgrade/parallel points to reef
Radoslaw Zarzynski [Tue, 22 Aug 2023 11:02:04 +0000 (11:02 +0000)]
qa: qa/suites/rados/upgrade/parallel points to reef

```
$ git rm qa/suites/rados/upgrade/parallel
$ ln -s ../../upgrade/reef-x/parallel qa/suites/rados/upgrade/parallel
$ git add qa/suites/rados/upgrade/parallel
```

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoqa: drop filestore-remove-check from upgrade/reef-x
Radosław Zarzyński [Tue, 29 Aug 2023 13:03:51 +0000 (15:03 +0200)]
qa: drop filestore-remove-check from upgrade/reef-x

FileStore is removed in Reef.

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agoqa: bring qa/suites/upgrade/reef-x
Radoslaw Zarzynski [Tue, 22 Aug 2023 10:37:44 +0000 (10:37 +0000)]
qa: bring qa/suites/upgrade/reef-x

Bases on quincy-x.

```
$ cp -R qa/suites/upgrade/quincy-x/ qa/suites/upgrade/reef-x
$ git add qa/suites/upgrade/reef-x
$ git mv qa/suites/upgrade/reef-x/filestore-remove-check/1-ceph-install/quincy.yaml qa/suites/upgrade/reef-x/filestore-remove-check/1-ceph-install/reef.yaml
$ find qa/suites/upgrade/reef-x/ -type f -exec sed -i 's/quincy/reef/g' {} +
```

A note from rebase: changes from 05e24270a2efe85bcdceade87b0e91efcfca3001
have been pulled in.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoqa: bring test_telemetry_reef.sh for squid
Radosław Zarzyński [Tue, 29 Aug 2023 13:12:00 +0000 (15:12 +0200)]
qa: bring test_telemetry_reef.sh for squid

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agoqa: bring test_telemetry_reef_x.sh for squid
Radoslaw Zarzynski [Tue, 22 Aug 2023 10:57:52 +0000 (10:57 +0000)]
qa: bring test_telemetry_reef_x.sh for squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoqa: stubs and clean up for reef
Radoslaw Zarzynski [Tue, 22 Aug 2023 10:29:51 +0000 (10:29 +0000)]
qa: stubs and clean up for reef

- remove upgrades from octopus
- stubs for completing upgrade to reef

Still missing the quincy-x upgrade tests.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agocommon, mon, qa: Mon-related updates for squid
Radoslaw Zarzynski [Tue, 22 Aug 2023 10:23:10 +0000 (10:23 +0000)]
common, mon, qa: Mon-related updates for squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agomon: update for squid ondisk features
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:33:58 +0000 (14:33 +0000)]
mon: update for squid ondisk features

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agodoc/dev/release-checklists: mark ceph-release-notes is already done
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:24:44 +0000 (14:24 +0000)]
doc/dev/release-checklists: mark ceph-release-notes is already done

This happened in 5d944bb237cb92ea2b13d668a78b939438836574.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agodoc/dev/release-checklists: mark backport-resolve-issue is already done
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:22:31 +0000 (14:22 +0000)]
doc/dev/release-checklists: mark backport-resolve-issue is already done

This happened in 3d15f685a88f5d10e3e8c023e9eb15bb4800bed5.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoceph-volume: change to squid
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:17:42 +0000 (14:17 +0000)]
ceph-volume: change to squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoinclude/ceph_features: retire deprecated bits
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:15:02 +0000 (14:15 +0000)]
include/ceph_features: retire deprecated bits

Nothing has been deprecated in Mimic, so this commit is just
updates the release checklist.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agodoc, mon: add always_on_modules for squid
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:08:37 +0000 (14:08 +0000)]
doc, mon: add always_on_modules for squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agodoc, qa/standalone/mon/misc: verify that len(monmap.features.persistent) == 11
Radoslaw Zarzynski [Mon, 21 Aug 2023 14:00:15 +0000 (14:00 +0000)]
doc, qa/standalone/mon/misc: verify that len(monmap.features.persistent) == 11

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agocephadm: update DEFAULT_IMAGE_RELEASE to squid
Radoslaw Zarzynski [Mon, 21 Aug 2023 13:51:02 +0000 (13:51 +0000)]
cephadm: update DEFAULT_IMAGE_RELEASE to squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agotools/monmaptool, test/cli, doc: pacific to quincy for default min_mon_release
Radoslaw Zarzynski [Wed, 10 May 2023 09:57:46 +0000 (09:57 +0000)]
tools/monmaptool, test/cli, doc: pacific to quincy for default min_mon_release

This is modelled after 4210e0a95e267d6297f53903ebd143108b134434.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoinclude/ceph_features, doc: define FEATURE_SERVER_SQUID
Radosław Zarzyński [Tue, 9 May 2023 17:24:07 +0000 (19:24 +0200)]
include/ceph_features, doc: define FEATURE_SERVER_SQUID

I've departed from 35d483af5425eb08593bc1c3065cfaec99938244
in that way the _incarnation_ is selected to be the very next
one to the retired bit's one.

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agocommon, doc, include, mds, mon: add feature/release name squid
Radosław Zarzyński [Tue, 9 May 2023 16:05:46 +0000 (18:05 +0200)]
common, doc, include, mds, mon: add feature/release name squid

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agoceph_release, doc: bump to 19/squid
Radosław Zarzyński [Tue, 9 May 2023 15:45:42 +0000 (17:45 +0200)]
ceph_release, doc: bump to 19/squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agocmake, doc: bump librbd version to 19.0.0 for squid
Radosław Zarzyński [Tue, 9 May 2023 15:43:39 +0000 (17:43 +0200)]
cmake, doc: bump librbd version to 19.0.0 for squid

Signed-off-by: Radosław Zarzyński <rzarzyns@redhat.com>
19 months agocmake, doc: bump project version to 19.0.0 for squid
Radoslaw Zarzynski [Tue, 9 May 2023 14:36:45 +0000 (14:36 +0000)]
cmake, doc: bump project version to 19.0.0 for squid

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agodoc/dev/release-checklists: uncheck everything!
Radoslaw Zarzynski [Tue, 9 May 2023 14:34:23 +0000 (14:34 +0000)]
doc/dev/release-checklists: uncheck everything!

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
19 months agoMerge pull request #54441 from phlogistonjohn/jjm-cephadm-breakup v19.0.0
Adam King [Mon, 4 Dec 2023 12:32:52 +0000 (07:32 -0500)]
Merge pull request #54441 from phlogistonjohn/jjm-cephadm-breakup

cephadm: break various daemon type classes out to smaller files in cephadmlib

Reviewed-by: Adam King <adking@redhat.com>
19 months agoMerge pull request #54679 from Suyashd999/add-rgw
Adam King [Mon, 4 Dec 2023 12:26:13 +0000 (07:26 -0500)]
Merge pull request #54679 from Suyashd999/add-rgw

src/cephadm: Added rgw for listing in Daemons

Reviewed-by: Adam King <adking@redhat.com>
19 months agoMerge pull request #54076 from rhcs-dashboard/subvolume-snapshot
Nizamudeen A [Mon, 4 Dec 2023 08:42:51 +0000 (14:12 +0530)]
Merge pull request #54076 from rhcs-dashboard/subvolume-snapshot

mgr/dashboard: cephfs subvolume list snapshots

Reviewed-by: Pedro Gonzalez Gomez <pegonzal@redhat.com>
Reviewed-by: Ankush Behl <cloudbehl@gmail.com>
Reviewed-by: ivoalmeida <NOT@FOUND>
19 months agoMerge pull request #54758 from zdover23/wip-doc-2023-12-03-rados-stretch-mode-repair...
Anthony D'Atri [Sun, 3 Dec 2023 14:40:46 +0000 (09:40 -0500)]
Merge pull request #54758 from zdover23/wip-doc-2023-12-03-rados-stretch-mode-repair-of-54689

doc/rados: repair stretch-mode.rst

19 months agodoc/rados: repair stretch-mode.rst 54758/head
Zac Dover [Sun, 3 Dec 2023 12:17:46 +0000 (13:17 +0100)]
doc/rados: repair stretch-mode.rst

Remove a section of doc/rados/operations/stretch-mode.rst that I wrongly
re-included after its removal. The request for this (re)-removal is
here: https://github.com/ceph/ceph/pull/54689#discussion_r1413007655.

Signed-off-by: Zac Dover <zac.dover@proton.me>
19 months agoMerge pull request #54437 from Matan-B/wip-matanb-crimson-osdmap-trimming
Matan Breizman [Sun, 3 Dec 2023 08:06:33 +0000 (10:06 +0200)]
Merge pull request #54437 from Matan-B/wip-matanb-crimson-osdmap-trimming

crimson/osd: introduce osdmap trimming

Reviewed-by: Samuel Just <sjust@redhat.com>
19 months agoMerge pull request #53712 from ronen-fr/wip-rf-move-1
Ronen Friedman [Sun, 3 Dec 2023 07:51:41 +0000 (09:51 +0200)]
Merge pull request #53712 from ronen-fr/wip-rf-move-1

osd: fix a missing 'noexcept' on a move ctor

Reviewed-by: Samuel Just <sjust@redhat.com>
19 months agoMerge pull request #54482 from ronen-fr/wip-rf-repl-hp
Ronen Friedman [Sun, 3 Dec 2023 07:45:18 +0000 (09:45 +0200)]
Merge pull request #54482 from ronen-fr/wip-rf-repl-hp

osd/scrub: decouple being reserved from handling scrub requests

Reviewed-by: Samuel Just <sjust@redhat.com>
19 months agoMerge pull request #54689 from PC-Admin/update-stretch-mode-docs
zdover23 [Sun, 3 Dec 2023 05:56:59 +0000 (06:56 +0100)]
Merge pull request #54689 from PC-Admin/update-stretch-mode-docs

doc/rados: Update stretch mode docs.

Reviewed-by: Zac Dover <zac.dover@gmail.com>
19 months agodoc/rados: update "stretch mode" 54689/head
PC-Admin [Tue, 28 Nov 2023 09:45:52 +0000 (17:45 +0800)]
doc/rados: update "stretch mode"

Update stretch mode docs, min_size and max_size are no longer defined in
the CRUSH map and the example rule given will fail to compile.

Specify that the tiebreaker data centre cannot be defined in CRUSH as
this produces an error.

Signed-off-by: Michael Collins <perthserverplus@gmail.com>
19 months agoosd: fix a missing 'noexcept' on a move ctor 53712/head
Ronen Friedman [Thu, 28 Sep 2023 12:04:06 +0000 (07:04 -0500)]
osd: fix a missing 'noexcept' on a move ctor

as a non-default, non-noexcept move ctor is ignored by
stl containers.

See clang-tidy's performance-noexcept-move-constructor

Signed-off-by: Ronen Friedman <rfriedma@redhat.com>
19 months agoMerge pull request #54752 from zdover23/wip-doc-2023-12-02-radosgw-multisite-formatting
zdover23 [Sat, 2 Dec 2023 06:22:12 +0000 (07:22 +0100)]
Merge pull request #54752 from zdover23/wip-doc-2023-12-02-radosgw-multisite-formatting

doc/radosgw: fix formatting

Reviewed-by: Anthony D'Atri <anthony.datri@gmail.com>
19 months agodoc/radosgw: fix formatting 54752/head
Zac Dover [Sat, 2 Dec 2023 05:38:28 +0000 (06:38 +0100)]
doc/radosgw: fix formatting

Repair the formatting of a string that had a string inside backticks
that itself was inside double asterisks. The presence of the asterisks
around the entire string caused the backticks to appear in the rendered
documentation.

Signed-off-by: Zac Dover <zac.dover@proton.me>
19 months agoMerge pull request #54526 from cbodley/wip-rgw-acl-cleanup
Casey Bodley [Fri, 1 Dec 2023 16:46:33 +0000 (16:46 +0000)]
Merge pull request #54526 from cbodley/wip-rgw-acl-cleanup

rgw/acl: clean up RGWAccessControlPolicy and friends

Reviewed-by: Yuval Lifshitz <ylifshit@redhat.com>
19 months agoMerge pull request #54488 from cbodley/wip-versioned-variant
Casey Bodley [Fri, 1 Dec 2023 16:02:20 +0000 (16:02 +0000)]
Merge pull request #54488 from cbodley/wip-versioned-variant

common: add versioned encodings for std::variant

Reviewed-by: Adam C. Emerson <aemerson@redhat.com>
19 months agotests/scrub: deactivate osd-scrub-dump stand-alone test 54482/head
Ronen Friedman [Fri, 1 Dec 2023 14:48:49 +0000 (08:48 -0600)]
tests/scrub: deactivate osd-scrub-dump stand-alone test

as the scrub reservation changes had made it obsolete.
Note - it is not an issue of fixing the test, but rather
that the tested functionality is no longer there.

Signed-off-by: Ronen Friedman <rfriedma@redhat.com>
19 months agocommon: add generate_test_instances() for std::variant 54488/head
Casey Bodley [Tue, 14 Nov 2023 19:43:25 +0000 (14:43 -0500)]
common: add generate_test_instances() for std::variant

Signed-off-by: Casey Bodley <cbodley@redhat.com>
19 months agocommon: add versioned encodings for std::variant
Casey Bodley [Tue, 14 Nov 2023 01:05:47 +0000 (20:05 -0500)]
common: add versioned encodings for std::variant

adds two encoding strategies for `std::variant<>` under the namespaces
`ceph::versioned_variant` and `ceph::converted_variant`

these versioned encodings allow the variant to be extended with new
types, provided that they're always added to the end without changing
or removing existing types. because of this requirement, no default
encoding is provided for `std::variant`. callers must opt in to one
namespace or the other

the `converted_variant` encoding requires the variant's first type T
to use versioned encoding, and guarantees that the variant's encoding
is backward-compatible with T's

Signed-off-by: Casey Bodley <cbodley@redhat.com>
19 months agomgr/dashboard: fs snapshots e2e 54076/head
Nizamudeen A [Fri, 27 Oct 2023 08:15:44 +0000 (13:45 +0530)]
mgr/dashboard: fs snapshots e2e

Fixes: https://tracker.ceph.com/issues/63237
Signed-off-by: Nizamudeen A <nia@redhat.com>
19 months agomgr/dashboard: cephfs subvolume list snapshots
Nizamudeen A [Wed, 18 Oct 2023 17:46:09 +0000 (23:16 +0530)]
mgr/dashboard: cephfs subvolume list snapshots

Added a tab for displaying the subvolume snapshots
- this tab will show an info alert when there are no subvolumes present
- if the subvolume is present, then it'll be auto-selected by default

Implemented a filter to search the groups and subvolumes by its name.
Also added a scrollbar when there are too many items in the nav list

Modified the REST APIs to fetch only the names of the resources and
fetch the info when an API call is requesting for it.

Added unit tests

Fixes: https://tracker.ceph.com/issues/63237
Signed-off-by: Nizamudeen A <nia@redhat.com>
19 months agoMerge pull request #54648 from rhcs-dashboard/fs-rename-fix
Nizamudeen A [Fri, 1 Dec 2023 12:51:49 +0000 (18:21 +0530)]
Merge pull request #54648 from rhcs-dashboard/fs-rename-fix

mgr/dashboard: fs rename only when fs is offline

Reviewed-by: Pedro Gonzalez Gomez <pegonzal@redhat.com>
Reviewed-by: Ankush Behl <cloudbehl@gmail.com>
Reviewed-by: ivoalmeida <NOT@FOUND>
19 months agoMerge pull request #54731 from zdover23/wip-doc-2023-11-30-rados-tshooting-log-and...
zdover23 [Fri, 1 Dec 2023 10:43:24 +0000 (11:43 +0100)]
Merge pull request #54731 from zdover23/wip-doc-2023-11-30-rados-tshooting-log-and-debug-note

doc/rados: improve formatting of log-and-debug.rst

Reviewed-by: Anthony D'Atri <anthony.datri@gmail.com>
19 months agoMerge pull request #54730 from zdover23/wip-doc-2023-11-30-glossary-monitor-store
zdover23 [Fri, 1 Dec 2023 09:44:41 +0000 (10:44 +0100)]
Merge pull request #54730 from zdover23/wip-doc-2023-11-30-glossary-monitor-store

doc/glossary.rst: add "Monitor Store"

Reviewed-by: Anthony D'Atri <anthony.datri@gmail.com>
19 months agodoc/rados: improve formatting of log-and-debug.rst 54731/head
Zac Dover [Thu, 30 Nov 2023 08:16:38 +0000 (09:16 +0100)]
doc/rados: improve formatting of log-and-debug.rst

Improve the arrangment of information in the section "Ceph Subsystems"
in doc/rados/troubleshooting/log-and-debug.rst.

Co-authored-by: Anthony D'Atri <anthony.datri@gmail.com>
Signed-off-by: Zac Dover <zac.dover@proton.me>
19 months agoMerge pull request #54724 from ajarr/wip-63673
Ilya Dryomov [Fri, 1 Dec 2023 09:33:10 +0000 (10:33 +0100)]
Merge pull request #54724 from ajarr/wip-63673

qa/workunits/rbd/cli_generic.sh: narrow race window

... when checking that rbd_support module command fails after blocklisting the module's client.

Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
19 months agomgr/dashboard: generalized code-block component 54648/head
Nizamudeen A [Thu, 30 Nov 2023 09:04:41 +0000 (14:34 +0530)]
mgr/dashboard: generalized code-block component

Fixes: https://tracker.ceph.com/issues/63608
Signed-off-by: Nizamudeen A <nia@redhat.com>
20 months agocephadm: black format daemons/tracing.py 54441/head
John Mulligan [Thu, 9 Nov 2023 18:59:07 +0000 (13:59 -0500)]
cephadm: black format daemons/tracing.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/snmp.py
John Mulligan [Thu, 9 Nov 2023 18:58:53 +0000 (13:58 -0500)]
cephadm: black format daemons/snmp.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/nvmeof.py
John Mulligan [Thu, 9 Nov 2023 18:58:41 +0000 (13:58 -0500)]
cephadm: black format daemons/nvmeof.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/nfs.py
John Mulligan [Thu, 9 Nov 2023 18:58:30 +0000 (13:58 -0500)]
cephadm: black format daemons/nfs.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/monitoring.py
John Mulligan [Thu, 9 Nov 2023 18:58:17 +0000 (13:58 -0500)]
cephadm: black format daemons/monitoring.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/iscsi.py
John Mulligan [Thu, 9 Nov 2023 18:58:03 +0000 (13:58 -0500)]
cephadm: black format daemons/iscsi.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/ingress.py
John Mulligan [Thu, 9 Nov 2023 18:57:49 +0000 (13:57 -0500)]
cephadm: black format daemons/ingress.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/custom.py
John Mulligan [Thu, 9 Nov 2023 18:57:34 +0000 (13:57 -0500)]
cephadm: black format daemons/custom.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: black format daemons/ceph.py
John Mulligan [Thu, 9 Nov 2023 18:57:15 +0000 (13:57 -0500)]
cephadm: black format daemons/ceph.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: convert all deploy tests to use funkypatch fixture
John Mulligan [Thu, 9 Nov 2023 19:26:35 +0000 (14:26 -0500)]
cephadm: convert all deploy tests to use funkypatch fixture

During the refactor of various daemon type classes some of the tests had
been converted to funkypatch in order to deal with imports occuring over
multiple files. However, this conversion was done piece by piece in
order to make clear what was changing. This left the functions in this
file inconsistent. Change all the remaining function to use funkypatch
for consistency.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: sort imports import daemons/__init__.py
John Mulligan [Thu, 9 Nov 2023 18:49:03 +0000 (13:49 -0500)]
cephadm: sort imports import daemons/__init__.py

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move ceph classes to a new file
John Mulligan [Thu, 9 Nov 2023 18:46:45 +0000 (13:46 -0500)]
cephadm: move ceph classes to a new file

Move the ceph classes (Ceph, OSD, CephExporter) along with a few heavily
linked functions to a new ceph.py file under the daemons dir.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move snmp class to a new file
John Mulligan [Thu, 9 Nov 2023 18:11:21 +0000 (13:11 -0500)]
cephadm: move snmp class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move monitoring class to a new file
John Mulligan [Thu, 9 Nov 2023 18:02:20 +0000 (13:02 -0500)]
cephadm: move monitoring class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move nfs class to a new file
John Mulligan [Thu, 9 Nov 2023 14:57:56 +0000 (09:57 -0500)]
cephadm: move nfs class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move iscsi class to a new file
John Mulligan [Thu, 9 Nov 2023 00:42:27 +0000 (19:42 -0500)]
cephadm: move iscsi class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move nvmeof class to a new file
John Mulligan [Thu, 9 Nov 2023 00:34:58 +0000 (19:34 -0500)]
cephadm: move nvmeof class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move haproxy and keepalived classes to a new file
John Mulligan [Thu, 9 Nov 2023 00:23:20 +0000 (19:23 -0500)]
cephadm: move haproxy and keepalived classes to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move tracing class to a new file
John Mulligan [Wed, 8 Nov 2023 21:04:15 +0000 (16:04 -0500)]
cephadm: move tracing class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: move custom container class to a new file
John Mulligan [Wed, 8 Nov 2023 20:58:36 +0000 (15:58 -0500)]
cephadm: move custom container class to a new file

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: start a cephadmlib.daemons package
John Mulligan [Wed, 8 Nov 2023 20:45:13 +0000 (15:45 -0500)]
cephadm: start a cephadmlib.daemons package

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephamd: update tests to use should_log_to_journald from context_getters
John Mulligan [Thu, 9 Nov 2023 18:46:04 +0000 (13:46 -0500)]
cephamd: update tests to use should_log_to_journald from context_getters

Update tests to import should_log_to_journald from context_getters - the
module that actually defines that function. This makes later refactoring
easier.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: update tests to import dict_get* functions from proper module
John Mulligan [Thu, 9 Nov 2023 14:57:24 +0000 (09:57 -0500)]
cephadm: update tests to import dict_get* functions from proper module

Update the test that import dict_get and dict_get_join to use the
context_getters module - the module that actually defines the functions.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: use funkypatch for setting up common patches in deploy tests
John Mulligan [Thu, 9 Nov 2023 00:21:10 +0000 (19:21 -0500)]
cephadm: use funkypatch for setting up common patches in deploy tests

Add a shim function and convert to the use of the FunkyPatcher class in
the test_deploy.py test functions. Use a shim as to not have to change
all the tests (yet).

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: create deployment_utils module
John Mulligan [Sun, 5 Nov 2023 21:03:53 +0000 (16:03 -0500)]
cephadm: create deployment_utils module

Create a deployment_utils module for deployment related functions that
don't have a better home.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: convert test_mon_crush_location to use funkypatch fixture
John Mulligan [Wed, 8 Nov 2023 19:31:12 +0000 (14:31 -0500)]
cephadm: convert test_mon_crush_location to use funkypatch fixture

The test_mon_crush_location test always seems to have me tinkering
with it during refactoring. Re-do the fixtures to use funkpatch instead
of mock.patch and normal monkeypatch. This looks nicer (IMO) and should
avoid having to frequently mess with it when moving functions during future
refactoring.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: update test to use funkypatch fixture
John Mulligan [Sun, 20 Aug 2023 17:50:31 +0000 (13:50 -0400)]
cephadm: update test to use funkypatch fixture

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: add a new funkypatch fixture based on mock.patch and pytest
John Mulligan [Sun, 20 Aug 2023 17:50:00 +0000 (13:50 -0400)]
cephadm: add a new funkypatch fixture based on mock.patch and pytest

This fixture acts like a combination of mock.patch and pytest's
monkeypatch fixture. It has the additional feature of automatically
finding and patching the same object imported in other modules.  If you
have 'from x import y', where y is a function or class, in both a.py and
b.py it will patch both instances (so long as both a and b are already
imported).
This behavior is useful for cephadm because of the heavy use of the
`from x import y` idiom and how cephadm is being actively refactored.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agocephadm: add a make_run_dir function
John Mulligan [Sun, 5 Nov 2023 21:03:34 +0000 (16:03 -0500)]
cephadm: add a make_run_dir function

This function is roughly the same as make_var_run only it doesn't rely
on shelling out to the install command. Eventually, it will be used
to replace make_var_run in certain locations.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
20 months agorgw/acl: remove virtual destructor of ACLGranteeType 54526/head
Casey Bodley [Tue, 28 Nov 2023 13:51:41 +0000 (08:51 -0500)]
rgw/acl: remove virtual destructor of ACLGranteeType

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl: ACLGrant uses variant for grantee types
Casey Bodley [Sat, 18 Nov 2023 16:27:50 +0000 (11:27 -0500)]
rgw/acl: ACLGrant uses variant for grantee types

use of `ACLGrant::get_id()` was awkward because most grantee types
returned nothing, but emails were returned as `struct rgw_user`. change
the internal representation into a variant, and expose getters for each
grantee type so callers can handle each type specifically. the encoded
format of `ACLGrant` remains unchanged

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl: req_state stores ACLs by value instead of unique_ptr
Casey Bodley [Sat, 18 Nov 2023 15:22:20 +0000 (10:22 -0500)]
rgw/acl: req_state stores ACLs by value instead of unique_ptr

we no longer rely on polymorphism for the s3/swift variants of
`RGWAccessControlPolicy`, so `req_state` can store `bucket_acl`,
`object_acl` and `user_acl` by value

most functions now take these acls by const- or mutable reference
instead of pointers since they won't be nullptr

some code paths won't initialize some of these bucket/object/user acl
variables, and we rely on `RGWAccessControlPolicy::verify_permissions()`
to return false for those because we won't match an empty owner or
array of grants

in only one case, `verify_user_permissions()` has to return true when
`user_acl` is uninitialized, because S3 doesn't have user acls so
uninitialized user acls should not deny access

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/s3: parse_policy() as free function
Casey Bodley [Sat, 18 Nov 2023 02:29:25 +0000 (21:29 -0500)]
rgw/acl/s3: parse_policy() as free function

s3 acl parsing classes no longer inherit from the acl classes
themselves, and are all encapsulated in rgw_acl_s3.cc behind a single
rgw::s3::parse_policy() function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/s3: write_policy_xml() as free function
Casey Bodley [Fri, 17 Nov 2023 20:31:17 +0000 (15:31 -0500)]
rgw/acl/s3: write_policy_xml() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/s3: create_policy_from_headers() as free function
Casey Bodley [Thu, 16 Nov 2023 21:38:31 +0000 (16:38 -0500)]
rgw/acl/s3: create_policy_from_headers() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/s3: create_canned_acl() as free function
Casey Bodley [Thu, 16 Nov 2023 20:13:25 +0000 (15:13 -0500)]
rgw/acl/s3: create_canned_acl() as free function

adds canned acls to base class RGWAccessControlPolicy

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl: use create_default() instead of empty canned acls
Casey Bodley [Thu, 16 Nov 2023 20:11:33 +0000 (15:11 -0500)]
rgw/acl: use create_default() instead of empty canned acls

create_default() adds the same default acl, without the relation to s3
canned acls

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: remove RGWAccessControlPolicy subclasses
Casey Bodley [Thu, 16 Nov 2023 19:05:36 +0000 (14:05 -0500)]
rgw/acl/swift: remove RGWAccessControlPolicy subclasses

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: format_account_acl() as free function
Casey Bodley [Thu, 16 Nov 2023 18:59:57 +0000 (13:59 -0500)]
rgw/acl/swift: format_account_acl() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: create_account_policy() as free function
Casey Bodley [Thu, 16 Nov 2023 18:59:18 +0000 (13:59 -0500)]
rgw/acl/swift: create_account_policy() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: add_grants() as static free function
Casey Bodley [Thu, 16 Nov 2023 18:43:19 +0000 (13:43 -0500)]
rgw/acl/swift: add_grants() as static free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: add_grants() uses user_to_grant() helper
Casey Bodley [Thu, 16 Nov 2023 18:42:21 +0000 (13:42 -0500)]
rgw/acl/swift: add_grants() uses user_to_grant() helper

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: format_container_acls() as free function
Casey Bodley [Thu, 16 Nov 2023 18:33:30 +0000 (13:33 -0500)]
rgw/acl/swift: format_container_acls() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: merge_policy() as free function
Casey Bodley [Thu, 16 Nov 2023 18:25:36 +0000 (13:25 -0500)]
rgw/acl/swift: merge_policy() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: create_container_policy() as free function
Casey Bodley [Thu, 16 Nov 2023 18:08:45 +0000 (13:08 -0500)]
rgw/acl/swift: create_container_policy() as free function

Signed-off-by: Casey Bodley <cbodley@redhat.com>
20 months agorgw/acl/swift: parse_grant() as static function
Casey Bodley [Thu, 16 Nov 2023 18:00:25 +0000 (13:00 -0500)]
rgw/acl/swift: parse_grant() as static function

Signed-off-by: Casey Bodley <cbodley@redhat.com>