Commit Graph
13292 Commits
Author SHA1 Message Date
Sébastien Han 23343927ca ceph: fix external bash script env var
s/CSI_RBD_NODE_SECRET_SECRET/CSI_RBD_NODE_SECRET

No need for the double SECRET

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 18:13:28 +01:00
Sébastien Han bce1474f06 ceph: add static IPAM support for CNI
We now support reading Network Attachment Definitions with a "static"
IPAM.
Also added more unit tests.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 17:59:34 +01:00
Sébastien Han d8de013443 ceph: use metav1.Duration for time CRD field
Previously, `interval` was just a string so no special validation was
done by the OpenAPI validator. Now that it is advertised as metav1.Duration
 the server will introspect it correctly. Underneath the type is still a
 string so no update issue to be worried about.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 12:12:31 +01:00
Sébastien Han e30cca076d Merge pull request #7467 from leseb/ci-add-user-group
ci: fix disk issue with crashing osd
2021-03-25 11:09:39 +01:00
Sébastien Han be576e9f51 Merge pull request #7441 from MaXinjian/RGW_POOL_PREFIX
docs: add a warning before running create-external-cluster-resources.sh
2021-03-25 10:56:11 +01:00
Sébastien Han 03613feeb2 ceph: set secret type on external cluster script
The secret type was missing earlier and must be set
to "kubernetes.io/rook" so that the operator does not complain.

Closes: https://github.com/rook/rook/issues/5732
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 10:30:42 +01:00
Sébastien Han 7069aa4f16 ci: fix disk issue with crashing osd
Let's try to create a 'ceph' user with the uid 167 and add it to the
'disk' group so that if the permissions on the disk change then the OSD
should be able to access the disk.

Closes: https://github.com/rook/rook/issues/7405
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 09:55:35 +01:00
Sébastien Han b59870a827 ci: timeout all commands in toolbox
Let's default to 15s, just like the CLI default timeout.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-25 09:52:39 +01:00
Ma Xinjian 46b8ded3a1 docs: add a warning before running create-external-cluster-resources.sh
If we don't export RGW_POOL_PREFIX firstly, RGW_POOL_PREFIX will be set to
default value, which is "default". Add a warning in document to give user
instructions.

Signed-off-by: Ma Xinjian <maxj.fnst@cn.fujitsu.com>
2021-03-25 09:59:35 +08:00
Sébastien Han a196e8c0a1 ci: skip any cleanup if a test fails
If a CI test fails we don't want to cleanup anything and leave the
cluster in the state it is. This will help debugging the CI.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-24 19:03:09 +01:00
Sébastien Han 37d5c106ad ceph: fix init container "expand-encrypted-bluefs" multipath
When running encrypted OSDs on multipath the expand container was
failing to find the underlying device of the encrypted block. This was
because the underlying block was located in /dev/mapper and this path
wasn't mounted in the init container "expand-encrypted-bluefs".

This will manifest like so:

```
Underlying device for crypt device ocs-deviceset-block-dev-from-san-1-data-0-5qkmm-block-dmcrypt disappeared.
```

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-24 18:48:31 +01:00
Sébastien Han 4ef2162d17 Merge pull request #7459 from leseb/rm-used
ceph: remove unsed type field
2021-03-24 17:18:46 +01:00
Blaine Gardner 3096a7e7f0 Merge pull request #7469 from cloudical-io/docs_fixes
docs: remove left overs in /dev/mapper/ceph--*
2021-03-24 09:49:02 -06:00
Sébastien Han 52c56cfde4 Merge pull request #7466 from leseb/multipath-encryption
ceph: fix init container "expand-encrypted-bluefs" multipath
2021-03-24 15:25:50 +01:00
Sébastien Han 89e57dc807 Merge pull request #7051 from subhamkrai/gh-action-matrix
ci: it test to run on multiple k8s version for master/release
2021-03-24 14:46:27 +01:00
Alexander Trost ce5c6f5927 docs: fix disaster recovery mon patch command
This removes the curly brackets from the json patch used to remove the
livenessProbe of the mon pod. At least in 1.18+ otherwise the patch
fails with a "cryptic" error.

Resolves #7460

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2021-03-24 14:34:59 +01:00
Alexander Trost 055dcb1863 docs: remove left overs in /dev/mapper/ceph--*
During Ceph teradown these files also need to be removed as well.

This is a continuation of the closed PR #7395.

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2021-03-24 14:34:47 +01:00
Sébastien Han 5762ca43b2 ceph: fix init container "expand-encrypted-bluefs" multipath
When running encrypted OSDs on multipath the expand container was
failing to find the underlying device of the encrypted block. This was
because the underlying block was located in /dev/mapper and this path
wasn't mounted in the init container "expand-encrypted-bluefs".

This will manifest like so:

```
Underlying device for crypt device ocs-deviceset-block-dev-from-san-1-data-0-5qkmm-block-dmcrypt disappeared.
```

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-24 10:35:12 +01:00
Sébastien Han 09cb5d6b4a ceph: remove unsed type field
isExternal was not used anymore so let's remove it.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-23 10:31:37 +01:00
Sébastien Han 9cf788091a Merge pull request #7454 from leseb/vault-default-path
ceph: set default backend for vault and remove temp key
2021-03-22 18:25:03 +01:00
Sébastien Han a394640286 ceph: remove temp encryption key
Once we are done opening the block device, we should remove the key even
though it is mounted on a tmpfs.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-22 17:00:12 +01:00
Sébastien Han dd275a2906 ceph: set default vault backend path when not specified
If the path was not specified, the OSD init container would crash loop,
failing to reach the vault path.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-22 16:56:41 +01:00
Sébastien Han 3f6257c751 Merge pull request #7431 from subhamkrai/yamllint-silence-warning
ci: silence yamllint warnings
2021-03-22 11:31:12 +01:00
subhamkrai 61ba7ec45a ci: it test to run on multiple k8s version for master/release
this commit enables IT to run on multiple k8s version
and for master/release, all the 5 k8s version
'v1.15.12','v1.16.15','v1.18.15','v1.19.7','v1.20.0'
similar to jenkins.

Signed-off-by: subhamkrai <srai@redhat.com>
2021-03-22 15:55:01 +05:30
Travis Nielsen 3bbc358d32 Merge pull request #7440 from travisn/mgr-labels
ceph: Set active mgr label on mgr services
2021-03-19 11:16:33 -06:00
Travis Nielsen c78e6a9e20 ceph: set active mgr label on mgr services
Other resources such as the service monitor need to match
the labels on the services to the active mgr, thus the active
mgr name is now set on the labels for the metrics service
and dashboard service.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-18 16:37:01 -06:00
Travis Nielsen 4d06ad1155 Merge pull request #7415 from subhamkrai/placement
ceph: placement in case of both PVC and non-PVC's
2021-03-18 12:33:02 -06:00
Sébastien Han e7c3e2c064 Merge pull request #7435 from aruniiird/fix-create-external-script-random-failure
ceph: fix for the random script failures because of open file issue
2021-03-18 16:57:35 +01:00
Arun Kumar Mohan 822a5194da ceph: fix for the random script failures because of open file issue
Script's tests were failing randomly because of an unclosed file
exceptions.

Signed-off-by: Arun Kumar Mohan <amohan@redhat.com>
2021-03-18 20:59:24 +05:30
subhamkrai 378c1c8506 ci: silence yamllint warnings
this commit silence yamllint warnings

Signed-off-by: subhamkrai <srai@redhat.com>
2021-03-18 15:38:01 +05:30
Sébastien Han c43058a98c Merge pull request #7355 from leseb/more-disks-ci
ceph: add more osds to the ci
2021-03-18 10:56:19 +01:00
Sébastien Han f13563d674 Merge pull request #7432 from leseb/csi-block-owner
ceph: fix csi blocker owner deletion
2021-03-18 10:38:09 +01:00
Sébastien Han 461dcd7457 ceph: fix csi blocker owner deletion
Small regression introduced in https://github.com/rook/rook/commit/26c8fd9bd14178d74dcc28f009e5c2f658224436
which was overriding the BlockOwnerDeletion from the ownerref.
Now, if set we don't modify it.
This fixes deployments on OCP.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-03-18 09:50:52 +01:00
Sébastien Han 67c669f183 Merge pull request #7425 from subhamkrai/gh-multi-k8s
ci: run gh action on multiple k8s version
2021-03-18 09:20:42 +01:00
subhamkraiandTravis Nielsen 319e4a41a4 ceph: placement in case of both PVC and non-PVC's
In the case of PVC,
We are giving lower priority to all placement.
We want deviceSet placement to applied and
override in case of overlapping settings and
we are merging nodeAffinity if applied in both
all placement and deviceSet.

In case of non-PVC,
we apply spec.placement

Signed-off-by: subhamkrai <srai@redhat.com>
Co-authored-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-18 10:32:57 +05:30
subhamkrai 07df8220d8 ci: run gh action on multiple k8s version
this commit enables gh action to run

Flex test on only 'v1.15.12',
Smoke and Helm tests on both 'v1.15.12','v1.20.2',
Mgr, Multicluster and upgrade tests on only 'v1.20.2'

Signed-off-by: subhamkrai <srai@redhat.com>
2021-03-18 09:03:56 +05:30
Travis Nielsen 7b3244a324 Merge pull request #7390 from travisn/refactor-tests
ceph: Refactor integration tests for simplification
2021-03-17 13:51:37 -06:00
Travis Nielsen 65fb9e0d92 Merge pull request #7419 from fritchie/maxsize-optional
ceph: mark maxSize as optional
2021-03-17 13:45:53 -06:00
Travis Nielsen deb7c21f98 ceph: install pre-1.16 crds with helm chart
The helm chart was not installing the CRDs on pre-1.16 k8s due
to a regression in the conditionals for the chart that was introduced
with 7103.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 13:10:53 -06:00
Travis Nielsen bdbf264e68 ceph: integration tests in github actions skip cleanup
The integration tests run independently in the github actions so there is
no need to cleanup from every test. The cleanup is still needed in the
Jenkins tests where all the suites run serially.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 11:26:11 -06:00
Travis Nielsen c23238cddb ceph: refactor integration tests for simplification
The integration tests have long been painful to maintain with
settings in various places and copied to multiple types,
inconsistent variable names, and otherwise difficult to maintain
code. Now the settings for a test suite are all in one place and
they remain in the same settings type throughout the test.
The multi-cluster suite is also refactored to use the same install
and uninstall helpers as the other suites.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 11:26:10 -06:00
Travis Nielsen f50e49be3a ceph: object store user initialization check for nil
If the object store status is not yet initialized, the object store user should
fail its initialization and requeue the reconcile.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 08:39:26 -06:00
Travis Nielsen 64e28af741 ceph: allow flex driver and discovery to be enabled with configmap
For testing purposes, we need to configure the flex driver
and discovery daemon with the operator settings configmap.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 08:39:26 -06:00
Travis Nielsen 933113eac8 ceph: remove obsolete storeType setting
All clusters are configured with bluestore as the store type
therefore we can remove the settings where mentioned in the
docs and dead code.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-03-17 08:39:25 -06:00
Frank Ritchie 7fcd0ab3d9 ceph: mark maxSize as optional
This is a follow up to:

https://github.com/rook/rook/pull/7397

Looks like I forgot to mark maxSize as optional.

Signed-off-by: Frank Ritchie <12985912+fritchie@users.noreply.github.com>
2021-03-17 09:43:31 -04:00
Sébastien Han 913e2c97f7 Merge pull request #7417 from anmolsachan/add_osd_slow_ops_alert
ceph: add osd slow ops alert
2021-03-16 16:21:03 +01:00
Travis Nielsen 32c628108c Merge pull request #7416 from leseb/debug-ci
ci: debug runners on failures
2021-03-16 08:57:32 -06:00
Travis Nielsen 014793c7ee Merge pull request #7340 from rohan47/clusterrole-multus
ceph: updated rbac for multus in helm charts
2021-03-16 08:49:12 -06:00
Travis Nielsen 4d969a406f Merge pull request #7414 from sp98/skip-cluster-cleanup
ceph: skip cleanup if cluster is not configured correctly.
2021-03-16 08:24:24 -06:00
rohan47 f3a75216a8 ceph: updated rbac for multus in helm charts
The rbac required for multus was present in role which makes
only the network-attachment-definitions in the rook cluster namespace
accessible to the operator. Moved it to clusterrole for cluster wide
access to NAD.

Signed-off-by: rohan47 <rohgupta@redhat.com>
2021-03-16 19:40:17 +05:30