Commit Graph
8169 Commits
Author SHA1 Message Date
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
Travis Nielsen d24d2a0fc9 Merge pull request #9610 from rook/mergify/bp/release-1.8/pr-9586
csi: add support to create volumesnapshotclass (backport #9586)
2022-01-19 10:42:38 -07:00
Satoru Takeuchi 638741890c core: support priority class for crashcollector
Support priorityClass to crashcollectors as mons, mgrs, and osds.

https://rook.io/docs/rook/v1.8/ceph-cluster-crd.html#priority-class-names-configuration-settings

The main use case is applying the high priority to crashcollectors to preempt normal pods
under heavy load. Without this feature, we might lose crash information.

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

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
(cherry picked from commit 5465481e0b)
2022-01-19 17:39:28 +00:00
Madhu Rajanna 6e45d4730a csi: add support to create volumesnapshotclass
add support for helm charts to create default
volumesnapshotclass for cephfs and rbd

fixes: #9566

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 85dc212704)
2022-01-19 17:00:33 +00:00
mergify[bot] 960bb7fcc8 Merge pull request #9607 from rook/mergify/bp/release-1.8/pr-9547
mon: add annotation to mon secret and cm (backport #9547)
2022-01-19 15:15:29 +00:00
mergify[bot] f07ed8dc1e Merge pull request #9606 from rook/mergify/bp/release-1.8/pr-9605
csi: restrict csiaddons to use only 1 port (backport #9605)
2022-01-19 15:09:06 +00:00
subhamkrai 2e0c595d33 mon: add annotation to mon secret and cm
add annotations to secrets and configmaps to use
different tools to sync secrets and configmap.
Currently, these annotation is applied only on
the `rook-ceph-mon-endpoints` configmap and
the secrets `rook-ceph-mon` and `rook-ceph-admin-keyring`.

Closes: https://github.com/rook/rook/issues/8999
Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit 02d43e82e0)
2022-01-19 14:51:31 +00:00
yati1998 d229cd4c8d csi: restrict csiaddons to use only 1 port
This commit restrict csiaddons to open only 1 port
as per the requirement which is required for security.

Fixes: #9604

Signed-off-by: yati1998 <ypadia@redhat.com>
(cherry picked from commit c559bbdf6b)
2022-01-19 14:43:50 +00:00