Commit Graph
7872 Commits
Author SHA1 Message Date
Blaine Gardner dd85bd2d33 helm: move rbd-csi-nodeplugin from PSP resources
Move the rbd-csi-nodeplugin ClusterRoleBinding from the chart PSP
resources to its proper place with the rest of the operator-wide
ClusterRoleBindings.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-11-17 16:34:54 -07:00
Travis Nielsen 54a2b56b0c Merge pull request #9167 from parth-gr/mons-CRname
mon: update mons Cluster ClusterInfo with CR name
2021-11-15 11:11:09 -07:00
Sébastien Han 2a5cbe9401 Merge pull request #9140 from travisn/default-s5-arch
build: Default to amd64 arch for the the s5cmd tool
2021-11-15 16:42:33 +01:00
Sébastien Han c5783a77cf Merge pull request #9163 from y1r/add-context-k8sutil-node
core: add context parameter to k8sutil node
2021-11-15 16:25:13 +01:00
Travis Nielsen 716baf7785 Merge pull request #9158 from Omar007/fix/blkdevmapper-capabilities
osd: set blkdevmapper capabilities
2021-11-15 08:05:12 -07:00
Sébastien Han d5643b439d Merge pull request #9161 from y1r/add-context-k8sutil-daemonset
core: add context parameter to k8sutil daemonset
2021-11-15 15:14:44 +01:00
Sébastien Han f44b943a7c Merge pull request #9162 from y1r/add-context-k8sutil-job
core: add context parameter to k8sutil job
2021-11-15 15:13:54 +01:00
Satoru Takeuchi 07e1ca678a Merge pull request #9168 from cybozu-go/core-fix-unnecessary-option
core: remove unnecessary option
2021-11-15 22:50:08 +09:00
Yuichiro Ueno 4cc716a7ca core: add context parameter to k8sutil node
This commit adds context parameter to k8sutil node functions. By this,
we can handle cancellation during API call of node resource.

Signed-off-by: Yuichiro Ueno <y1r.ueno@gmail.com>
2021-11-15 22:45:59 +09:00
Yuichiro Ueno 3799542356 core: add context parameter to k8sutil job
This commit adds context parameter to k8sutil job functions. By this, we
can handle cancellation during API call of job resource.

Signed-off-by: Yuichiro Ueno <y1r.ueno@gmail.com>
2021-11-15 22:39:08 +09:00
parth-gr 242f98e94b mon: update mons Cluster ClusterInfo with CR name
the mons re-initialize its ClusterInfo which results in missing
CR name on the ClusterInfo
Set the CR name to the mons cluster ClusterInfo

Closes: https://github.com/rook/rook/issues/9159
Signed-off-by: parth-gr <paarora@redhat.com>
2021-11-15 18:52:55 +05:30
Omar Pakker 4726d39688 osd: set blkdevmapper capabilities
The OSD blkdevmapper init container relies on the MKNOD capability,
which it does not actually request.
As a result, deployments fail on Kubernetes clusters that do not
happen to assign this capability to all containers by default.
Solve this by updating the container spec securityContext to
explicitly request the capability it relies on.

Closes: https://github.com/rook/rook/issues/9156
Signed-off-by: Omar Pakker <Omar007@users.noreply.github.com>
2021-11-15 13:11:19 +01:00
Satoru Takeuchi 77e7c249cc core: remove unnecessary option
rook command doesn't interpret `logtostderr` option. It's OK to just
remove this option because `capnslog` outputs all logs to stdout
by default. It's better to keep `AddGoFlagSet()` call because
some libraries might define their own flags with Go's `flag` package.

Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
2021-11-15 11:53:45 +00:00
Sébastien Han 7d87de838e Merge pull request #8994 from parth-gr/external-cluster-permission
security: update auth permissions for external cluster
2021-11-15 12:32:39 +01:00
Sébastien Han ecd7fa7880 Merge pull request #9164 from y1r/add-context-k8sutil-pod
core: add context parameter to k8sutil pod
2021-11-15 11:58:36 +01:00
Sébastien Han 460cfad0de Merge pull request #9160 from y1r/add-context-k8sutil-deployment
core: add context parameter to k8sutil deployment
2021-11-15 11:44:20 +01:00
Yuichiro Ueno 0559977b8a core: add context parameter to k8sutil pod
This commit adds context parameter to k8sutil pod functions. By this, we
can handle cancellation during API call of pod resource.

Signed-off-by: Yuichiro Ueno <y1r.ueno@gmail.com>
2021-11-13 15:39:41 +09:00
Yuichiro Ueno e278812cc1 core: add context parameter to k8sutil daemonset
This commit adds context parameter to k8sutil daemonset functions. By
this, we can handle cancellation during API call of daemonset resource.

Signed-off-by: Yuichiro Ueno <y1r.ueno@gmail.com>
2021-11-13 15:09:31 +09:00
Yuichiro Ueno 0b575703c7 core: add context parameter to k8sutil deployment
This commit adds context parameter to k8sutil deployment functions. By
this, we can handle cancellation during API call of deployment resource.

Signed-off-by: Yuichiro Ueno <y1r.ueno@gmail.com>
2021-11-13 14:58:13 +09:00
Travis Nielsen c3b5d3b078 Merge pull request #9155 from travisn/latest-doc-links
docs: Fix the links from docs to github examples in master branch
2021-11-11 17:27:47 -07:00
Travis Nielsen 839fdfe95d docs: fix the links to examples in master branch
With the recent rename of master docs to the latest docs,
the links from the docs back to github need to be generated
with the latest url instead of master.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-11 15:32:29 -07:00
Travis Nielsen 480c7f89f2 Merge pull request #9147 from Madhu-1/fix-emp-link
doc: fix ephemeral link for rbd pod
2021-11-11 07:52:27 -07:00
Madhu Rajanna 953cabf999 docs: fix ephemeral link for rbd pod
fixed the ephemeral link for the rbd pod.
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2021-11-11 20:04:55 +05:30
parth-gr 7d106c8e21 security: adding a cluster name suffix on ceph auth
Current auth names are inadequate for a ceph cluster
serving storage to muliple Openshift clusters
Added a clusterName as a suffix on ceph auth
principals for external cluster

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1996830
Signed-off-by: parth-gr <paarora@redhat.com>
2021-11-11 19:34:54 +05:30
Travis Nielsen 59729765bf build: default to amd64 arch for the the s5cmd tool
On mac, the docker build was failing due to an unspecified
S5CMD_ARCH. Now we default to build amd64 always and override
it if the arch is arm64.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-10 12:25:57 -07:00
Travis Nielsen 901263f8fd Merge pull request #9137 from travisn/raise-rgw-error
rgw: Raise errors when rgw daemon fails to be created
2021-11-10 10:00:17 -07:00
Travis Nielsen 9ecd0cbc75 rgw: raise errors when rgw daemon fails to be created
The generation of the rgw deployment spec was swallowing errors
if any issues are raised such as the tls cert not being found
as expected in some configurations. We need to fail the reconcile
so the error will be logged and the admin can identify the issue.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-10 09:13:03 -07:00
Sébastien Han f07c944aaa Merge pull request #9128 from travisn/cephfs-helm-expansion
helm: Enable cephfs volume expansion by default
2021-11-10 15:02:39 +01:00
parth-gr fc64ce3fc4 security: update rbd auth permissions for external cluster
The permissions set for ceph auth principals for
external storage are too broad, which leads to
maintenance and security risk
Modified auth principals permissions to specific pools

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1996829
Signed-off-by: parth-gr <paarora@redhat.com>
2021-11-10 14:23:04 +05:30
Blaine Gardner 9e3ee92152 Merge pull request #9081 from subhamkrai/composite-action
ci: use github composition to reduce duplication
2021-11-09 11:36:58 -07:00
Sébastien Han 7a4f3966c4 Merge pull request #9130 from leseb/fix-4968
core: add s5cmd binary to operator image
2021-11-09 17:33:31 +01:00
Sébastien Han 889856b78f core: add s5cmd binary to operator image
The toolbox can now interact with S3 gateways using the `s5cmd` tool.
The binary is only 12M so this does not add up too much to the operator
image size.

Closes: https://github.com/rook/rook/issues/4968
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-09 16:56:30 +01:00
Travis Nielsen 35e3ebd1d2 helm: enable cephfs volume expansion by default
The cluster helm chart missed adding the default setting
for the volume expansion, so now we enable it by default.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-09 07:35:02 -07:00
Travis Nielsen 54d532b623 Merge pull request #9125 from sp98/update-scc
core: add `AllowHostDirVolumePlugin: true` to SCC and remove unused imports
2021-11-09 07:26:28 -07:00
subhamkrai 99358688d8 ci: use github composition to reduce duplication
Using Github Compositoin to reduce the yaml duplication.
https://github.blog/changelog/2021-08-25-github-actions-reduce-duplication-with-action-composition/

Closes: https://github.com/rook/rook/issues/8637
Signed-off-by: subhamkrai <srai@redhat.com>
2021-11-09 16:41:55 +05:30
Sébastien Han 8cfaedcbf6 Merge pull request #9127 from leseb/fix-9090
ci: wait for kubeproxy to be ready
2021-11-08 18:16:57 +01:00
Sébastien Han 0e26176b54 ci: wait for kubeproxy to be ready
When requesting issuer, we run a local kubectl proxy command which spawn
a proxy server. However, we must wait for the proxy to be ready before
we actually start making requests to it.
Now the CI waits up to 10sec to retrieve the issuer.

Closes: https://github.com/rook/rook/issues/9090
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-08 17:45:53 +01:00
Santosh Pillai 650a451d65 core: remove unused imports
removed unused import of embed package from scc.go file

Signed-off-by: Santosh Pillai <sapillai@redhat.com>
2021-11-08 19:56:47 +05:30
Santosh Pillai 584b3bd328 core: add AllowHostDirVolumePlugin: true to SCC
Adds AllowHostDirVolumePlugin to the go representation of the rook-ceph
SCC for using the hostPath. Also making it consistent with the yaml
representation.

From Openshift docs

For backwards compatibility, the usage of allowHostDirVolumePlugin overrides
settings in the volumes field. For example, if allowHostDirVolumePlugin is
set to false but allowed in the volumes field, then the hostPath
value will be removed from volumes.

Signed-off-by: Santosh Pillai <sapillai@redhat.com>
2021-11-08 19:55:54 +05:30
Satoru Takeuchi cd4862a7f7 Merge pull request #9123 from leseb/fix-arm64
ci: fix arm64 job
2021-11-08 20:19:11 +09:00
Sébastien Han dd351a914a Merge pull request #9122 from leseb/error-on-failure
core: fail if config dir creation fails
2021-11-08 09:51:51 +01:00
Sébastien Han d081a3e764 ci: fix arm64 job
They are no arm64 packages for ceph-nfs so we must skip this validation
for the nightly arm64 CI job.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-08 09:18:23 +01:00
Sébastien Han 10a114a45a core: fail if config dir creation fails
If the operator fails to create the operator's configuration directory
then we should fail the Operator.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-08 08:48:35 +01:00
Travis Nielsen 6f4a68c81f Merge pull request #9116 from travisn/osd-prepare-cleanup-timeout
osd: Increase wait timeout for osd prepare cleanup
2021-11-05 15:11:09 -06:00
Travis Nielsen 427996a7c0 osd: increase wait timeout for osd prepare cleanup
When a reconcile is started for OSDs, the prepare jobs are first
deleted from a previous reconcile. The timeout for the osd prepare
job deletion was only 40s. After that timeout, the reconcile attempts
to continue waiting for the pod, but of course will never complete
since the OSD prepare was not running in the first place, causing the
reconcile to wait indefinitely. In the reported issue, the osd prepare
jobs were actually deleted successfully, the timeout just wasn't long
enough. Pods need at least a minute to be forcefully deleted,
so we increase the timeout to 90s to give it some extra buffer.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-05 14:20:43 -06:00
Sébastien Han 3b85de420f Merge pull request #8744 from leseb/fix-8734
ceph: run operator with rook user
2021-11-05 17:56:54 +01:00
Sébastien Han d06a6f93a5 core: run operator with rook user
The rook operator as well as the toolbox pod run with the "rook" user
with UID 2016. The UID was chosen based on the year of the initial
commit in the rook/rook repository.
No more root user running.

Closes: https://github.com/rook/rook/issues/8734
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-05 17:22:04 +01:00
Sébastien Han 1294d511fc Merge pull request #9086 from leseb/build-for-linux-only
build: only produce binary for linux
2021-11-05 17:18:16 +01:00
Travis Nielsen be48cc8028 Merge pull request #9107 from travisn/ec-maximum
pool: Allow more data chunks in an ec pool
2021-11-05 10:13:06 -06:00
Travis Nielsen 53b6c7128e pool: allow more data chunks in an ec pool
The schema has a limit of 9 data and 9 coding chunks in an EC pool.
While not typically recommended, more data chunks may be desired.
Ceph does not have a limit, so we match the behavior and also
allow any number of desired chunks to be specified.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-05 08:27:46 -06:00