Commit Graph
5036 Commits
Author SHA1 Message Date
travisn 417f05311f exporter: ignore failed deletion of service monitor
If the ceph version does not suppport the exporter, the operator
will attempt to delete the service monitor related to the exporter
to ensure it does not exist for a node. If the expected rbac does
not exist, this will cause unnecessary errors since there would anyway
be no service monitor to delete. So we ignore the error of deleting
the service monitor for the exporter.

The context is also passed to the exporter so a new kubeconfig does
not need to be initiated and cause unnecessary logging about
invalid options for the config.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-06-26 12:26:09 -06:00
dependabot[bot] 0d2c3c914f build(deps): bump github.com/aws/aws-sdk-go from 1.44.288 to 1.44.289
Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) from 1.44.288 to 1.44.289.
- [Release notes](https://github.com/aws/aws-sdk-go/releases)
- [Commits](https://github.com/aws/aws-sdk-go/compare/v1.44.288...v1.44.289)

---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 10:40:54 -06:00
travisn c4ec275946 build: update to latest go modules as much as possible
The go modules are updated to the latest client-go, vault,
and other modules. There does not appear to be a combination
of modules that will allow us to use vault v1.13.3, so we
stick with v1.13.2.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-06-23 07:44:17 -06:00
travisn 557a3e06cc core: api updates for controller runtime v0.15
For the controller runtime v0.15 there are some breaking
changes to the api that need to be updated.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-06-22 10:33:28 -06:00
dependabot[bot] 96bc058296 build(deps): bump sigs.k8s.io/controller-runtime from 0.14.5 to 0.15.0
Bumps [sigs.k8s.io/controller-runtime](https://github.com/kubernetes-sigs/controller-runtime) from 0.14.5 to 0.15.0.
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](https://github.com/kubernetes-sigs/controller-runtime/compare/v0.14.5...v0.15.0)

---
updated-dependencies:
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-21 15:10:38 -06:00
Blaine Gardner e3f1515f43 Merge pull request #12396 from BlaineEXE/multus-tool-add-config-file
multus: add config file for validation tool
2023-06-21 09:48:08 -06:00
Travis Nielsen d7dcf58f7c Merge pull request #12406 from polyedre/confusing-message
Fix confusing successful message when reconciling CephObjectStoreUser
2023-06-20 13:12:55 -06:00
Blaine Gardner f8d9076a38 multus: add config file for validation tool
Allow the validation tool to read test config from a yaml file. To help
users, also allow outputting a config file with default values and
comments instructing how to use the config file.

This work is in anticipation of adding more advanced configuration
options that would be too cumbersome to set using cli flags.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-06-20 11:54:37 -06:00
Travis Nielsen 9a8e93cee8 Merge pull request #12341 from thotz/add-tls-secret-ref-in-objectstoreuser-secret
object : add ssl ref in cephobjectstore user secret
2023-06-20 10:20:35 -06:00
Lucas Henry 87bc3dfcdc operator: remove confusing successful message when reconciling CephObjectStoreUser
When creating a CephObjectStoreUser with a value spec.store that refers to an
unexisting CephObjectStore, after the reconciliation loop the
CephObjectStoreUser is in the ReconcileFailed state. However, a
ReconcileSucceeded event is created with this message:

"successfully configured CephObjectStoreUser"

The success message results of the return value for the error which is currently
`nil`. Let's replace it with the error message.

Signed-off-by: Lucas Henry <polyedre@disroot.org>
2023-06-20 11:02:04 +02:00
YZ775 ed9da20d68 operator: add ceph image version label to PVC
This PR makes Rook operator to add a label on PVC that contains an image version of Ceph when creating an OSD.

Signed-off-by: YZ775 <yuzuki-mimura@cybozu.co.jp>
2023-06-19 08:19:46 +09:00
Sachin Prabhu 8705f2b37e nfs: set correct kerberos domain in /etc/idmapd.conf
We add a new field domainName to the Kerberos section. The field is used
to setup /etc/idmapd.conf with the domain name. This allows idmapper to
map to kerberos credential to the correct uid/gid.

We add Spec.Security.Kerberos.DomainName to the CRD

Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
2023-06-09 18:06:45 +01:00
Jiffin Tony Thottan 6ea24cb11b object: add ssl ref in cephobjectstore user secret
There is no reference for ssl in cephobjectstore Secret, so users won't
have much idea why tls secret need to used. Hence give reference
object stores tls secret ref in the Secret.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2023-06-09 12:42:35 +05:30
Tarun Gupta Akirala df0ce26923 core: typo in logs to print fullname of CephCluster
printing namespace along with name would make debugging easier

Signed-off-by: Tarun Gupta Akirala <takirala@users.noreply.github.com>
2023-06-07 14:42:00 -07:00
avanthakkar 541d091f9c core: use ROOK_CEPH_MON_HOST from config store in OSD pods too
Signed-off-by: avanthakkar <avanjohn@gmail.com>

Volume "ceph-daemons-sock-dir" is coming empty in case if dataDirHostPath,
which is the case for osd onPVC. Fix the volume creation by using the
ceph cluster spec dataDirHostPath, which allows to run socket commands
on osd containers.
2023-06-01 21:09:58 +05:30
Travis Nielsen 13c7c6bae5 Merge pull request #12271 from avanthakkar/cleanup-exporter
core: cleanup exporter resources
2023-05-31 15:14:37 -06:00
avanthakkar 41a8294510 core: cleanup exporter resources
Cleanup exporter daemon even if ceph version is not supported along with other resources like
metrics service and service monitor.
Signed-off-by: avanthakkar <avanjohn@gmail.com>
2023-06-01 02:04:17 +05:30
Travis Nielsen f6da90d539 Merge pull request #12264 from parth-gr/rgw-external-tls
external: fqdn should be persisted
2023-05-31 14:00:59 -06:00
parth-gr f66de7b9df external: fqdn should be persisted
1) donot change rgw fqdn to ip if provided,
As now the bucket class supports the
entry of fqdn

2) update crds with new description in EndpointAddress

Signed-off-by: parth-gr <paarora@redhat.com>
2023-05-31 17:36:29 +05:30
Blaine Gardner b2babf01d2 Merge pull request #12282 from BlaineEXE/multus-validation-ci-test
test: add CI e2e test for multus validation test
2023-05-31 01:37:14 +02:00
Travis Nielsen 6417ed4047 Merge pull request #12256 from thotz/add-missing-caps-object-user
object: add missing caps for object store user
2023-05-30 16:37:18 -06:00
Travis Nielsen 351751ac72 Merge pull request #12302 from Javlopez/feature/11429-use-default-for-logging-to-stderr
core: use -default-* flags
2023-05-30 13:05:02 -06:00
Javier 02e17196f2 core: use -default-* flags
enable flags with --default prefix for --log-to-stderr, --mon-cluster-log-to-stderr, --err-to-stderr, and --log-stderr-prefix

Signed-off-by: Javier <sjavierlopez@gmail.com>
2023-05-30 11:52:26 -06:00
Travis Nielsen 44a986396e Merge pull request #12293 from ulagbulag/fix-rook_cluster-bug-in-service-monitor
mgr: update default rook_cluster of ServiceMonitor
2023-05-30 11:10:52 -06:00
Ho Kim 42caef169f mgr: update default rook_cluster of ServiceMonitor
When deploying a cluster with Helm Chart, if the namespace is not the default value `rook-ceph`, and if the monitoring feature is enabled, then the generated ServiceMonitor's `rook_cluster` selector now follows the namespace, not the hard-coded value `rook-ceph`.

Signed-off-by: Ho Kim <ho.kim@ulagbulag.io>
2023-05-30 23:58:50 +09:00
Jiffin Tony Thottan 1f45cfa581 object: use networkspec from clusterinfo spec while running radosgw-admin
The radosgw-admin command uses the network spec from ceph cluster spec
in object context but it is not filled properly in the object package.
But with PR 10898, network spec is available in clusterinfo which can
be used directly. Also removed cluserspec from object context.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2023-05-30 11:06:03 +05:30
Blaine Gardner d0995c8d76 test: fix nginx image client template error
Regarding Go templates: when inside a range, the base dot (.) context is
not available, so anything used within the range must be set to a
shell-style variable.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-05-26 12:20:15 -06:00
Jiffin Tony Thottan ad0c000e6a object: add missing caps for object store user
Lot of new caps added to rgw users, reflecting same changes on the
object store user CRD.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2023-05-26 17:36:00 +05:30
iPraveenParihar 78d6528153 test: allow specifying custom nginx image for multus validation
Allow overriding the nginx server image used for the web server and clients from CLI with --nginx-image flag.
Set default image in flag as 'nginxinc/nginx-unprivileged:stable-alpine'

Signed-off-by: iPraveenParihar <praveenparihar68@gmail.com>
2023-05-24 21:04:24 +05:30
Blaine Gardner 943128dce4 Merge pull request #12211 from BlaineEXE/pull-image-to-all-nodes-before-multus-validate
operator: pull multus validation test images before test
2023-05-19 22:39:31 +02:00
Blaine Gardner 73c39ca5b4 Merge pull request #11598 from opencmit/fix-11592
nfs: adding RGW section in ganesha.conf
2023-05-18 21:46:51 +02:00
Travis Nielsen 6cdf60a41d Merge pull request #12247 from travisn/rbd-reconcile-retry
rbdmirror: Retry reconcile if cluster not initialized
2023-05-17 17:25:54 -06:00
travisn 2877523137 rbdmirror: retry reconcile if cluster not initialized
The rbd mirror reconcile was not re-queuing the reconcile
if the cephcluster was not initialized. All other controllers
waiting for the initialization are requeuing the event,
just not the rbd mirror controller.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-05-17 15:47:17 -06:00
Travis Nielsen 9b99ab209c Merge pull request #12224 from travisn/dev-guide-review
docs: Dev guide review updates
2023-05-17 14:29:20 -06:00
Satoru Takeuchi 13e4464fed osd: supoprt expand lvm osd on pvc
The expansion of OSD on PVC is only supported in raw mode OSD.
It's nice to support lvm mode osd too.

Closes: https://github.com/rook/rook/issues/10835

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
2023-05-16 00:23:09 +00:00
Blaine Gardner 3a27cb60b3 operator: pull multus validation test images before test
Before starting multus validation test clients, pull the client image to
all nodes. This will ensure that variations in client readiness timing
will not be affected by variations in the time nodes take to pull the
image. This is intended to reduce the number of false reports of flaky
multus networks.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-05-11 16:00:33 -06:00
travisn 0f6b099403 docs: remove obsolete comments about old versions
Remove old mentions of rook or ceph versions that
are no longer relevant.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-05-11 11:45:04 -06:00
Travis Nielsen fd935f19a7 Merge pull request #12216 from travisn/no-service-mon-default
monitoring: Skip creating the service monitor for the exporter if monitoring is not enabled
2023-05-10 09:56:23 -06:00
travisn 1b80767877 monitoring: no service monitor by default for exporter
The exporter is enabled by default, but the service monitor
can only be enabled if prometheus CRDs are available. The
monitoring.enabled must be set to true as the flag that
prometheus is available and the service monitor should
be created.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-05-09 14:52:40 -06:00
avanthakkar 8a8eb863d0 core: add termination grace period for exporter pods
Shorten the termination time for exporter pod before it
gets deleted to avoid crashing of pod.
Signed-off-by: avanthakkar <avanjohn@gmail.com>
2023-05-10 02:16:12 +05:30
travisn 92a0ab37e3 monitoring: configurable option to disable prometheus metrics
The prometheus mgr module and ceph exporter can now be optionally
disabled by the monitoring.metricsDisabled setting in the
CephCluster CR. These will not be disabled by default, rather
than the mgr module being disabled by default from v1.11.4.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-05-05 16:04:51 -06:00
Madhu Rajanna 6f30700f5e core: disable controller runtime metrics server
As we are not using the controller runtime
metrics we dont even need to start the server
as its just uses extra resouces and its not
much useful.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2023-05-05 11:02:47 +02:00
s3rj1k dc55f23cba build: add Golang module for APIs
Create separate module for API for external projects to consume.

Signed-off-by: s3rj1k <evasive.gyron@gmail.com>
2023-05-03 21:26:16 +03:00
Madhu Rajanna 1139cefc94 core: unset all encryption configuration before setting
if the configuration is already set in the ceph
database, using `ceph config assimilate-conf`
will add the key and value if its missing but
it wont update the value if the key is already
present, To fix this problem we can remove the
key and add all the configurations once again.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2023-05-03 18:15:45 +02:00
Travis Nielsen 7fc93177ec Merge pull request #12110 from koor-tech/feature/1873-auto-generate-rook-CRD-specifications-documentation
docs: add support for autogenerated docs for CRDs
2023-05-02 14:03:35 -06:00
Blaine Gardner cf17b8b454 Merge pull request #12155 from BlaineEXE/reduce-nfs-crd-size
nfs: pare down config file volume sources
2023-05-02 21:26:00 +02:00
Blaine Gardner 5a1d1f2175 Merge pull request #12069 from BlaineEXE/multus-golang-tester
test: add multus validation test routine to rook binary
2023-05-02 19:37:29 +02:00
Blaine Gardner 6500c11d57 nfs: pare down config file volume sources
Pare down the available volume sources for NFS config files so that the
CRD isn't unnecessarily huge. This allows us to recommend
`kubectl apply` again in the upgrade doc.

Size of the NFS CRD is reduced by approximately 60%.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-05-02 11:34:24 -06:00
Blaine Gardner 0f6e7ee921 test: add multus validation test routine to rook binary
Add a more involved multus validation test to the Rook binary. Because
this is intended to be end-user runnable, make sure operator-only
commands are hidden.

Build this into the rook binary instead of creating a separate binary
for ease, and because any binary built with the kube api becomes 40+
megabytes. We save quite a bit of space by including this in the Rook
binary, which is good for keeping container layers as small as possible.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-05-02 10:23:00 -06:00
parth-gr ed61d25fc3 mgr: fix ceph dashboard login issue
Dashboard ac-user-create cmd was taking more time
then the usual ceph command to run,
So increased the timeout to run the cmd, and
now dashboard admin user is sucessfully created

Closes: https://github.com/rook/rook/issues/12113
Signed-off-by: parth-gr <paarora@redhat.com>
2023-05-02 19:43:53 +05:30