Commit Graph
8176 Commits
Author SHA1 Message Date
Sébastien Han fccec1af0b subvolumegroup: handle external mode
If the cluster is external, users might still want to take advantage of
the ceph-csi configmap configuration for ceph filesystem subvolume
group. This configuration is handled by the controller whenever a
cephFilesystemSubVolumeGroup CR is created or deleted.
If the present cluster CephCluster is external, the controller
(cephFilesystemSubVolumeGroup) won't handle creation nor deletion of sub volume groups.
It just assumes that the given name is correct and the controller goes ahead with the
ceph-csi configuration.

Closes: #9551
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 49f75c8ec3)
2022-02-03 17:00:37 +00:00
Travis Nielsen 8fc67f7dbb Merge pull request #9677 from rook/mergify/bp/release-1.8/pr-9578
rgw: gateway deployment strategy RollingUpdate on Pacific (backport #9578)
2022-02-01 13:22:51 -07:00
mergify[bot] 27cbe17fe8 Merge pull request #9683 from rook/mergify/bp/release-1.8/pr-9680
csi: fix snapshot tests (backport #9680)
2022-01-31 15:33:09 +00:00
Madhu Rajanna f6a3417bf4 csi: fix snapshot CRD and controller cleanup oder
cleanup the CRD and controller in defer
to make sure the CRD and controller are
removed as filesystem/block test also
install CRD and controller separately.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 44353167d7)
2022-01-31 15:02:56 +00:00
Madhu Rajanna 53ea431695 csi: cover error cases in snapshot ready check
Currently, we sleep only if the snapshot is not ready
and try again, this covers only the happy path.
the checks might fail to get the snapshot object
or the `.status.readyToUse` might not be set yet.
First sleep and then try to check snapshot is
ready or not, if we do this we cover all the cases
when checking the snapshot ready status.
Changed sleep internal to do incremental sleep to
give more time for tests.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 97e5b78c11)
2022-01-31 15:02:55 +00:00
Sébastien Han e2957e284c Merge pull request #9674 from rook/mergify/bp/release-1.8/pr-9663
core: dereference pointer before trying to compare with deepequal (backport #9663)
2022-01-28 16:15:13 +01:00
micalgenus e3e070ca51 rgw: gateway deployment strategy rolling on Pacific
When the strategy type of deployment is Recreate, from the moment the end is
started until the new pod is normally running, there is no pod in the
kubernetes service endpoints, so it goes to the service unavailable state.

Therefore, it is necessary to change it to `type: RollingUpdate` instead of
`type: Recreate` so that rolling updates can be made without downtime.

Before Pacific, creating a deployment as much as the instance was okay,
but after Pacific, the replicas was increased in one deployment, so rolling
updates were set up one by one as in the previous version.

Signed-off-by: micalgenus <micalgenus@gmail.com>
(cherry picked from commit a68151e2f2)
2022-01-28 15:12:57 +00:00
Sébastien Han ce9b3ee2f2 core: dereference pointer before trying to compare with deepequal
Prior to this, we were comparing a pointer (the memory address) with a
struct. This was obviously always failing and returned false. We must
dereference the pointer to access the data contained at that memory
location.

Closes: https://github.com/rook/rook/issues/9544
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 5404ec13a2)
2022-01-28 10:20:40 +00:00
Travis Nielsen 4c41b5ea07 Merge pull request #9662 from rook/mergify/bp/release-1.8/pr-9658
osd: Merge all osd resources including custom (backport #9658)
2022-01-27 13:10:44 -07:00
Travis Nielsen ddc86b8416 Merge pull request #9666 from rook/mergify/bp/release-1.8/pr-9665
csi: bump csi snapshotter image to v5 (backport #9665)
2022-01-27 13:08:31 -07:00
mergify[bot] fb05bc2c80 Merge pull request #9668 from rook/mergify/bp/release-1.8/pr-9661
helm: add annotations and labels for VSC (backport #9661)
2022-01-27 19:20:23 +00:00
Travis Nielsen 6ca7da2bb2 csi: add patch permission to volumesnapshotcontents
The update to the snaphots 5.0 controller requires
rbac for patching the volumesnapshotcontents.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 3e4edc0f1d)
2022-01-27 12:14:05 -07:00
Madhu Rajanna 8885db9b86 csi: check deployment for snapshot controller
The external-snapshotter was deployed as statefulset
in 4.x and now its deployed as a deployment. updated
the check in CI to make sure deployment is created.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 53e12d687f)
2022-01-27 12:13:54 -07:00
Madhu Rajanna 954624b5fa helm: add annotations and labels for VSC
add support to specify annotations and
labels for the volumesnapshotclass.

closes: #9655

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 08dadaa486)
2022-01-27 18:52:22 +00:00
Madhu Rajanna 1d7fea8f52 csi: bump csi snapshotter image to v5
updating the csi-snapshotter and dependencies
to v5.0.1 released version.

Co-authored-by: Mathieu Parent <mathieu.parent@insee.fr>
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit cf46615688)
2022-01-27 09:32:45 -07:00
Travis Nielsen 0645de1d08 Merge pull request #9664 from rook/mergify/bp/release-1.8/pr-9651
Bump csi resizer and volume replication images (backport #9651)
2022-01-27 09:30:28 -07:00
Mathieu Parent 2cd55d7bd6 csi: bump csi resizer and volume replication images
Upgraded images:

- k8s.gcr.io/sig-storage/csi-resizer: v1.3.0 -> v1.4.0
- quay.io/csiaddons/volumereplication-operator: v0.1.0 -> v0.3.0

Detailed changelogs:

- https://github.com/kubernetes-csi/external-resizer/blob/release-1.4/CHANGELOG/CHANGELOG-1.4.md
- https://github.com/csi-addons/volume-replication-operator/tree/v0.2.0
- https://github.com/csi-addons/volume-replication-operator/tree/v0.3.0

Signed-off-by: Mathieu Parent <mathieu.parent@insee.fr>
(cherry picked from commit 88a449d09c)
2022-01-27 09:05:16 -07:00
Travis Nielsen 83f627a2e3 osd: merge all osd resources including custom
The merging of OSD resource limits and requests assumed
that only the cpu and memory resources needed to be merged.
It is also possible to set custom resource properties such
as intel.com/sriov_net_in: '1' for use with multus, so
the merging needs to be more general.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit f9ac966048)
2022-01-27 09:09:51 +00:00
mergify[bot] 560231ad14 Merge pull request #9657 from rook/mergify/bp/release-1.8/pr-9647
osd: allow for injecting extra env. variables via ConfigMap (backport #9647)
2022-01-26 16:53:38 +00:00
Radoslaw Zarzynski 98e9fe0fbc osd: allow for injecting extra env. variables via ConfigMap
This patch brings a mechanism to define arbitrary environment
variables in OSD containers (both prepare and main ones).
It bases on idea proposed by Sebastien Han to use an optional
`ConfigMap` instance named `aook-ceph-daemon-env-override`
as the source of these settings.

The need for the patch comes from the fact that, although
crimson finally exposes the same CLI interface as the classical
OSD, the broadly used development builds have ASan built in.
As ASan, by default, complains if it isn't the very first loaded
DSO, we need a way to set the `ASAN_OPTIONS` environment variable
to `verify_asan_link_order=0` to mitigate the early aborts.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
(cherry picked from commit 17ca41f557)
2022-01-26 16:27:51 +00:00
mergify[bot] 46293b5fad Merge pull request #9656 from rook/mergify/bp/release-1.8/pr-9654
core: fix some nits  (backport #9654)
2022-01-26 15:34:52 +00:00
Sébastien Han 50d240234e core: add a break line before printing the ceph config
It's easier to read the config if there is a new line before instead
having a truncated version like:

```
2022-01-26 06:39:41.421373 D | cephclient: config file @ /etc/ceph/ceph.conf: [global]
fsid                = 0650a1d5-d688-4575-97fc-7b3052a8a3dd
mon initial members = a
mon host            = [v2:10.104.192.209:3300,v1:10.104.192.209:6789]

[client.admin]
keyring = /var/lib/rook/rook-ceph/client.admin.keyring
```

Now we have:

```
2022-01-26 06:39:41.421373 D | cephclient: config file @ /etc/ceph/ceph.conf:
[global]
fsid                = 0650a1d5-d688-4575-97fc-7b3052a8a3dd
mon initial members = a
mon host            = [v2:10.104.192.209:3300,v1:10.104.192.209:6789]

[client.admin]
keyring = /var/lib/rook/rook-ceph/client.admin.keyring
```

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 58c175de47)
2022-01-26 15:07:30 +00:00
Sébastien Han d6fd12e999 core: print the stdout on errors
If we fail fetching the ceph version let's also print the stdout since
ceph tends to put the error here too.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit e31e4b49b0)
2022-01-26 15:07:30 +00:00
mergify[bot] 9568850d3a Merge pull request #9650 from rook/mergify/bp/release-1.8/pr-9649
pool: Check for application already being set (backport #9649)
2022-01-25 23:03:12 +00:00
Travis Nielsen f35da8d9c4 pool: check for application already being set
If the pool application is already set, skip setting it again
to avoid a warning message being logged that it is already
set.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit e0cfb4fce6)
2022-01-25 22:39:48 +00:00
mergify[bot] 3ead186868 Merge pull request #9644 from rook/mergify/bp/release-1.8/pr-9642
helm: Update CI to the latest helm and fix the linter (backport #9642)
2022-01-25 00:15:40 +00:00
mergify[bot] ae489d79c3 Merge pull request #9641 from rook/mergify/bp/release-1.8/pr-9565
rgw: inject tls certs for bucket notification and topic operations (backport #9565)
2022-01-24 23:47:52 +00:00
Travis Nielsen e1fd738dd8 helm: update to the latest helm version v3.8
The CI was building with helm 3.6.2, now updating to
the latest v3.8.0

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 50afb9f026)
2022-01-24 23:47:37 +00:00
Travis Nielsen beec916f00 helm: fix linter issue with end tag
Recent versions of helm are failing the linter on the end tag
if the tag is "{{- end -}}". Instead, the correct end tag
is "{{- end }}".

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit b1a0918d0e)
2022-01-24 23:47:36 +00:00
Jiffin Tony Thottan 0a8140463d rgw: inject tls certs for bucket notification and topic operations
The certs for accessing TLS enabled RGW is saved as secrets and inject
them if controllers for notification and topics if request is sent to
TLS enabled RGW endpoint.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
(cherry picked from commit a97747cece)
2022-01-24 18:56:39 +00:00
Satoru Takeuchi b2937fbe98 Merge pull request #9631 from rook/mergify/bp/release-1.8/pr-9603
rgw: handle the non-existence of the bucket correctly when removing bucket (backport #9603)
2022-01-22 05:51:32 +09:00
Travis Nielsen dc06a70c84 Merge pull request #9635 from travisn/release-1.8.3
build: Update the release version to v1.8.3
v1.8.3
2022-01-21 12:55:28 -07:00
Travis Nielsen c0e46c5721 build: update the release version to v1.8.3
With the patch release the example manifests and docs are updated to v1.8.3

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-01-21 11:57:49 -07:00
Travis Nielsen 782e2a3147 Merge pull request #9633 from rook/mergify/bp/release-1.8/pr-9627
csi: update cephcsi to 3.5.1 release (backport #9627)
2022-01-21 11:56:01 -07:00
Madhu Rajanna 64641a6ce8 csi: update cephcsi to 3.5.1 release
This PR updates the cephcsi version from
3.5.0 to 3.5.1 which includes minor fixes

fixes: #9619

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 39825f2302)
2022-01-21 18:30:10 +00:00
Yuma Ogami daa636b9f1 rgw: handle the non-existence of the bucket correctly when removing bucket
ceph might return NoSuchKey than NoSuchBucket when the target bucket does not exist.
then we can use GetBucketInfo() to judge the existence of the bucket.

see: https://github.com/ceph/ceph/pull/44413

Closes: https://github.com/rook/rook/issues/9494
Signed-off-by: Yuma Ogami <yuma-ogami@cybozu.co.jp>
(cherry picked from commit c4ee218da1)
2022-01-21 16:56:26 +00:00
mergify[bot] 312fd56783 Merge pull request #9630 from rook/mergify/bp/release-1.8/pr-9615
osd: rename a few configuration flags (backport #9615)
2022-01-21 14:50:55 +00:00
mergify[bot] de94acad37 Merge pull request #9629 from rook/mergify/bp/release-1.8/pr-9626
csi: updates the default csi-addons image (backport #9626)
2022-01-21 14:43:19 +00:00
mergify[bot] 468c0713f7 Merge pull request #9628 from rook/mergify/bp/release-1.8/pr-9484
csi: change rook-ceph-csi-config to expose clusterID for subvolume (backport #9484)
2022-01-21 14:38:28 +00:00
Sébastien Han a7f48d7cd2 ci: fix encryption test condition
For the "if" to work we need to bring the env in the step with the "env"
keyword. Otherwise, the env is never imported and the condition is
always false.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 802a86ccd5)
2022-01-21 14:27:19 +00:00
Sébastien Han b7bbb2198c osd: rename a few configuration flags
For better consistency with IBM_KP_SERVICE_API_KEY and use
"ibmkeyprotect" as a provider name for more clarity.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 7cc6e23a0b)
2022-01-21 14:27:18 +00:00
yati1998 aadd5f7ef8 csi: updates the default csi-addons image
This commit updates the csi-addons image version
from v0.1.0 to v0.2.1.
Also, this updates the staging path from
{{ .KubeletDirPath }}/plugins/kubernetes.io/csi/pv/ to
{{ .KubeletDirPath }}/plugins/kubernetes.io/csi/.

This changes is done as the reclaimspace on block mode
was not working.
For more details:
 https://github.com/csi-addons/kubernetes-csi-addons/pull/97

Signed-off-by: yati1998 <ypadia@redhat.com>
(cherry picked from commit 07c5fc7e46)
2022-01-21 14:17:14 +00:00
Sébastien Han b006674fea csi: change rook-ceph-csi-config to expose clusterID for subvolume
The rook-ceph-csi-config config map now includes CephFS subvolumegroups
when a subvolumegroup CR is created. It is useful for ceph-csi to
understand which subvolumegroup to use for a given cluster.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 739abf6662)
2022-01-21 14:13:39 +00:00
Sébastien Han 496fe25b84 subvolumegroup: fix code deletion
We want to log properly when ENOTEMPTY is caught during deletion, so
fixing the condition.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 640d30339d)
2022-01-21 14:13:38 +00:00
Sébastien Han 989fb34381 nfs: use hashing function from existing k8sutil package
We have a function to hash a string so let's use it.

Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 92ada52610)
2022-01-21 14:13:37 +00:00
mergify[bot] 9303fc30ab Merge pull request #9621 from rook/mergify/bp/release-1.8/pr-9074
helm: Apply operator settings in configmap instead of deployment (backport #9074)
2022-01-20 23:05:08 +00:00
Travis Nielsen 7470e51d5b helm: apply operator settings in configmap instead of deployment
Some operator settings can be applied dynamically in a configmap
instead of requiring the operator to restart. While these settings
may be infrequently updated, applying these settings in the configmap
can avoid an unnecessary operator restart. This will also make the
operator deployment more consistent with the non-helm install.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
(cherry picked from commit 741f211a13)
2022-01-20 22:38:33 +00:00
mergify[bot] 8957be1adf Merge pull request #9617 from rook/mergify/bp/release-1.8/pr-9613
core: reconcile operator configuration with env var (backport #9613)
2022-01-20 19:16:48 +00:00
Sébastien Han 08dd2b9732 core: reconcile operator configuration with env var
Previously, we were ignoring configuration changes coming from the
operator's pod env variables. We were assuming most users were using the
operator configmap "rook-ceph-operator-config" but most Helm users
don't. Now we will reconcile if a cephcluster is found during a CREATE
event (can be an operator restart or a cephcluster creation) AND no
"rook-ceph-operator-config" is found which means the operator's pod env
var are used.
Also, unit tests have been added (long due) for the predicate!

Closes: #9602, #9487, #9579
Signed-off-by: Sébastien Han <seb@redhat.com>
(cherry picked from commit 1208bc1410)
2022-01-20 16:53:40 +00:00
Satoru Takeuchi c8c0639704 Merge pull request #9611 from rook/mergify/bp/release-1.8/pr-9502
core: support priority class for crashcollector (backport #9502)
2022-01-20 03:43:22 +09:00