Commit Graph
1627 Commits
Author SHA1 Message Date
rohan47 f5bbc8c5c5 ceph: fix networkAttachmentConfig to be compatible with whereabouts cni
In the whereabouts config, the network range is determined by range
option unlike other cni plugins that use Subnet option.

Signed-off-by: rohan47 <rohgupta@redhat.com>
2020-08-05 21:17:13 +05:30
Sébastien Han 7d7523a8a2 ceph: fix unit test mock
Mock the user creation otherwise the health check fails and panics.

Closes: https://github.com/rook/rook/issues/5976
Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-05 16:09:24 +02:00
Sébastien Han 89b3225441 ceph: add encryption support for osd pvc
We can now encrypted OSD device that were provisioned via a storage
class using the PV interface.
The encryption works at the storageClassDeviceSets level, which means we
can have encrypted and non-encrypted sets.
Using the new key `encrypted` we can turn it on.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-05 10:06:11 +02:00
Sébastien Han af1e8c320a ceph: do not log an error if no clusters
If the list of cluster is empty there is no need to report an error in
the logs.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-08-05 10:05:51 +02:00
Travis Nielsen 06c21954e1 ceph: labels are immutable for match selectors
The labels cannot be updated on a deployment match selector.
In v1.4 a new label was added for ceph_daemon_type that is intended
to be on the pod labels, but cannot be applied to the match selectors.
Therefore, we suppress any new labels that are added to the daemons.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2020-08-04 16:47:00 -06:00
Madhu Rajanna 943f402216 ceph: create csidriver if kube version is >1.14
create csidriver object  if the kubernetes version
is greater than 1.14 modified the check to allow
Csidriver object creation if kubernetes major version
is greater than 1.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-04 20:46:28 +05:30
Travis Nielsen 34f7b2e4b7 Merge pull request #5950 from Madhu-1/cleanup
ceph: cleanup csi package
2020-08-03 16:16:44 -06:00
Madhu Rajanna dfce2b67d5 ceph: compare with major and minor kubernetes version
instead of skipping the checks based on the kubernetes
major version we need to check both major and minor
version of it.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 22:56:25 +05:30
Madhu Rajanna 4595f42bf5 ceph: remove unused file from csi
removed unused file from the csi folder

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 22:06:26 +05:30
Madhu Rajanna 29312743e1 ceph: remove unused variable
remove unused variable in spec.go

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 22:06:26 +05:30
Madhu Rajanna bf77614b66 ceph: log kubernetes version in spec
logging kubernetes version helps for
debugging the issue related to version miss
match.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 22:06:22 +05:30
Madhu Rajanna bb5bc927e0 ceph: correct the kubernetes version comparision
fixed the kubernetes version comparsion to
deploy provisioner as the statefulset.

if the kubernetes Major version is less than
1 or major  is 1 and minor is less than 14
deploy provisioner as statefulset

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 19:08:47 +05:30
Madhu Rajanna 1a5e9cb5dd ceph: rename resizer image variable
renamed resizer image variable as per
other variable names.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 19:07:45 +05:30
Madhu Rajanna 58b4c2d74d ceph: re-arrange import order in spec.go
re-arrange import order as per standard
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-08-03 19:04:46 +05:30
Jiffin Tony Thottan ec5f13318c ceph: enable/disable dashboard for rgw
Provide permission for dashboard to collect the object store metrics.

Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
2020-08-03 10:26:54 +05:30
Jiffin Tony Thottan 73b8a598d2 ceph: add support to create system user for createuser api
Currently this is no way to create user with system permission in objectstore.
Add support for the same

Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
2020-08-03 10:24:42 +05:30
Jiffin Tony Thottan ab607075da ceph: handles an user creation error if the store is missing
Currently if object store is missing user creation fails without throwing
any error. Here the access and secret key values will be checked post the
creation command

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-08-03 10:24:34 +05:30
Blaine Gardner cb6881e401 Merge pull request #5909 from SUSE/ceph-add-daemon-type-label
ceph: add ceph_daemon_type label to Ceph daemon pods
2020-07-31 09:40:48 -06:00
Jiffin Tony Thottan 091679cbeb ceph: use deleteOBCResourceLogError instead of deleteOBCResource
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-31 15:41:35 +05:30
Jiffin Tony Thottan 59f1e8364e ceph: fix up deleteOBCResourceLogError
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-31 15:41:31 +05:30
Travis Nielsen e0ea87a353 Merge pull request #5674 from thotz/quotaobc
ceph: adding support for quota in object bucket claims
2020-07-30 22:51:58 -06:00
Blaine Gardner dcf8ae2526 ceph: rename pod labels function for more clarity
Rename PodLabels function to CephDaemonAppLabels for more clarity about
what the function's purpose is.

Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2020-07-30 11:16:30 -06:00
Blaine Gardner 6ceaef8610 ceph: add new "ceph_daemon_type" label to nfs pods
Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2020-07-30 11:16:29 -06:00
Blaine Gardner 62cbaaec02 ceph: add new "ceph_daemon_type" label to osd pods
Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2020-07-30 11:16:26 -06:00
Blaine Gardner 9b6114c192 ceph: add 'ceph_daemon_type' label to pod labels
This can help users identify the daemon type similarly to how
'ceph_daemon_id' helps identify the daemon ID. This also makes it so
scripts users create don't have to parse "app=rook-ceph-<daemonType>"
into "<daemonType>" if they desire that bit of info.

Signed-off-by: Blaine Gardner <blaine.gardner@suse.com>
2020-07-30 11:16:22 -06:00
subhamkrai 0279025e9e ceph: handling all the gosec errors
a few of the gosec errors were left. so
this commit will resolve all the errors.

Signed-off-by: subhamkrai <subhamkumarrai03@gmail.com>
2020-07-30 08:19:55 +05:30
Travis Nielsen 704e80d1b5 Merge pull request #5912 from rohantmp/rohantmp-patch-1
Core: Add comment warning to keep k8sutil hashing consistent for name…
2020-07-28 10:41:47 -06:00
Travis Nielsen 1ee29b9c63 Merge pull request #5895 from subhamkrai/nosec-error
ceph: suppress gosec errors for g204,g304,g101
2020-07-28 08:25:58 -06:00
Travis Nielsen 9e6429b4c8 Merge pull request #5893 from subhamkrai/gosec-error-G601
ceph: handling gosec error code g601
2020-07-28 08:25:00 -06:00
Travis Nielsen f6b7aac3b6 Merge pull request #5908 from leseb/split-osd-files
ceph: split osd code in files
2020-07-28 07:37:46 -06:00
Rohan Joseph 82b062f91d core: add comment warning to keep k8sutil hashing consistent
The name generation utils need to provide consistent outputs across
versions so that names generated based on values are consistent and
older generated keys are not lost.

Signed-off-by: Rohan CJ <rohantmp@gmail.com>
2020-07-28 12:51:54 +05:30
Jiffin Tony Thottan f4240cb31d ceph: add quota support for obc
Closes: #5274
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-28 12:00:11 +05:30
Jiffin Tony Thottan 96a53389b1 ceph: adding new quota apis
Adding new apis such as EnableUserQuota() for enabling quota,
SetQuotaUserObjectMax() and SetQuotaUserMaxSize() for setting user specific quotas
for objects and size respectively. Please note the size is quota is determined in GBs.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-28 12:00:04 +05:30
Jiffin Tony Thottan 5a6cafcdfc ceph: add missing explaination for apis in user.go
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-28 11:59:57 +05:30
Jiffin Tony Thottan cf61966205 ceph: remove rgwerrno from setuserquota
Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2020-07-28 11:59:51 +05:30
subhamkrai 465a0f0aec ceph: handling gosec error code g601
this commit handles all the gosec g601
error code (i.e Implicit memory aliasing
of items from a range statement).

Signed-off-by: subhamkrai <subhamkumarrai03@gmail.com>
2020-07-28 11:34:49 +05:30
subhamkrai bcd7faed4e ceph: suppress gosec errors for g204, g304, g101
this commit suppress the gosec errors for

g204: Audit use of command execution.
g304: File path provided as taint input.
g101: Look for hard coded credentials.

Signed-off-by: subhamkrai <subhamkumarrai03@gmail.com>
2020-07-28 11:10:48 +05:30
Sébastien Han 71dff530d3 ceph: split osd code in files
Makes the code more readable and decoupled into files.

Signed-off-by: Sébastien Han <seb@redhat.com>
2020-07-27 23:21:14 +02:00
Travis Nielsen 22ba4591f3 Merge pull request #5888 from Madhu-1/csi-v3.0.0
ceph: update ceph-csi to v3.0.0 release
2020-07-27 14:05:29 -06:00
Madhu Rajanna cc3b4e6906 ceph: remove check for kubernetes version
as we are going to deploy snapshotter by
default we are going to remove the kubernetes
version check.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-27 13:45:56 +05:30
Madhu Rajanna 026c5ac28a ceph: update version check for v3.0.0 release
added v3.0.0 as supported release of cephcsi.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-27 13:30:44 +05:30
subhamkrai acc4ed5df9 ceph: handling gosec errors that are not checked
this commit handles all the gosec g104
i.e audit errors not checked inside pkg.

Signed-off-by: subhamkrai <subhamkumarrai03@gmail.com>
2020-07-24 20:02:06 +05:30
Travis Nielsen e1f296e34a Merge pull request #5880 from Madhu-1/fix-csi-ver
ceph: skip csi version detect if allowunsupported is set
2020-07-23 23:18:57 -06:00
Madhu Rajanna 031e3145a5 ceph: update cephcsi to v3.0.0
update cephcsi to latest available release

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-24 10:21:59 +05:30
Travis Nielsen 195a241833 Merge pull request #5881 from Madhu-1/tol-for-csi-ver
ceph: add provisioner toleration for csi version check job
2020-07-23 12:44:34 -06:00
Sébastien Han dcadf10f0c Merge pull request #5837 from leseb/external-connection
ceph: let the healthcheck set the status phase
2020-07-23 09:24:58 +02:00
Sébastien Han cf28b16b68 Merge pull request #5836 from subhamkrai/objectstore-liveness
ceph: ability to configure livenessprobe for cephobjectstore crd
2020-07-23 09:14:34 +02:00
Madhu Rajanna d6b2ad142d ceph: add provisioner toleration for csi version check job
Added a provisioner toleration to the csi version
check job, so that we can schedule the csi version
check on the node where the nodes are tainted.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-23 08:49:18 +05:30
Madhu Rajanna 51d3a52c80 ceph: skip csi version detect if allowunsupported is set
If the AllowUnsupported flag is set to true we should
not check the csi version as it will be kind of no-op
as even incase of failure we continue. if we disable
the version check in this case,the deployment will
be little faster as we dont wait for version check
to complete to start CSI pods.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2020-07-23 08:30:14 +05:30
Travis Nielsen 77e787b00e Merge pull request #5805 from kesavanvt/add_device_class
ceph: Adding deviceClasses info to CephCluster CR
2020-07-22 16:00:18 -06:00