Commit Graph

839 Commits

Author SHA1 Message Date
Madhu Rajanna
f4d05a3ef9 CSI: run all containers as privileged in daemonset pods
On systems with SELinux enabled, non-privileged containers
can't access data of privileged containers. Since the socket
is exposed by privileged containers, all sidecars must be
privileged too. This is needed only for containers running
in daemonset as we are using bidirectional mounts in daemonset

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit e0cc7740f6)
2020-01-16 19:32:28 +05:30
Sébastien Bernard
a816d41e4f Add missing env for namespace.
(cherry picked from commit 40b04d2f3a)
2020-01-02 03:49:20 +00:00
Madhu Rajanna
9829dc52c1 Enable logging in E2E if test fails
source: https://github.com/kubernetes/kubernetes/blob/master/test/e2e/framework/kubectl/kubectl_utils.go
kubectlLogPod function is not exposed in above code so copied it.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 7d15992769)
2019-12-18 13:17:31 +00:00
Madhu Rajanna
9b67982928 Enable Block E2E for rbd
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit b4f20e941c)
2019-12-18 13:17:31 +00:00
Madhu Rajanna
eddfc123e5 discard umount error if directory is not mounted
if the directory is not mounted return nil
during umount of mountPoint

Discard error if error is os.IsNotExist

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit dcafdb519e)
2019-12-17 14:10:00 +00:00
Madhu Rajanna
7912ec0040 Fix leader election flag in deployment files
Fixes: https://github.com/ceph/ceph-csi/issues/748

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit b849b7daaa)
2019-12-17 12:55:36 +00:00
Madhu Rajanna
cf9a10c7d0 Push v1.2-canary image from release-v1.2.0
as part of https://github.com/ceph/ceph-csi/pull/715/
we have updeated the release-v1.2.0 branch to
push v1.2.2 images as the release is done reverting back
the image tag to push canary image.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-11-21 14:14:37 +05:30
Madhu Rajanna
f8c854dc7d Prepare for release v1.2.2
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-11-21 10:11:52 +05:30
Niels de Vos
fa32e1022b cephfs: add kernel version detection for mounting with client
Linux kernel 4.17.0 adds support for quota with CephFS. Without quota,
it is not possible to fullfill the requirements of the CSI Spec and
guarantee sufficient space on the filesystem for a volume. With this in
mind, usage of the kernel client is only allowed with kernel 4.17.0 or
newer.

However, some Linux vendors backport features and patches to their
Enterprise products. These kernels may have an older version, but do
support quota. One of these is the kernel that comes with RHEL-7.7.

By comparing the current running version of the Linux kernel against
known versions that support quota, we can now automatically decide to
use the kernel client, or not.

Note that this does not change the 'forcekernelclient' parameter. The
parameter is still available and can be used for kernels that are not in
the 'known to support quota list'. Or users can pass the parameter to
use a CephFS kernel client that does not support quota.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 290beb4dda)
2019-11-13 12:35:37 +00:00
Madhu Rajanna
56bef16ad1 Fix issue in helm chat pushing
From master and release-v1.2.0 branch we will be
pushing the canary charts. when we are doing the release
i.e v1.2.2 from release-v1.2.0 branch we will replace
all canary to released tag v1.2.2 and push helm charts
for v.1.2.2 and will revert back the changes in
release-v1.2.0 branch push canary tagged charts(
this will be same logic as pushing the container image)

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 50268d5947)
2019-10-20 12:31:06 +05:30
Madhu Rajanna
6128c530ac Remove csi-v0.3 from deploy.sh
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 52c4d29f65)

# Conflicts:
#	.travis.yml
#	deploy.sh
2019-10-20 12:31:06 +05:30
Stefan Haas
953c2e166c Added forcecephkernelclient as startup parameter to force enabling ceph
Signed-off-by: Stefan Haas <shaas@suse.com>
(cherry picked from commit 6a2717ce20)
2019-10-16 07:24:58 +00:00
Jason Dillaman
2d16bc3ee9 Handle EACCESS error from 'ceph rbd task add remove'
If the RBD user does not have permissions to talk to the
Ceph MGR, it should gracefully fallback to the slower foreground
image deletion.

Fixes: #677
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit a274b19bfa)
2019-10-13 17:42:54 +00:00
Madhu Rajanna
a1cfc9c9ce reuse existing code for size Roundoff
This PR addresses the review comments in
https://github.com/ceph/ceph-csi/pull/644

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 239822f147)
2019-10-11 11:46:18 +00:00
Madhu Rajanna
8de7d9c90d Fix volsize for cephfs and rbd
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 7274bd09e5)
2019-10-11 09:01:49 +00:00
Madhu Rajanna
21352486b7 update registration directory name
updated cephfs registration directory
name to match with rbd implementaion

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 9287948991)
2019-10-10 07:54:23 +00:00
KingJ
4ba07092e8 Reorder kernel version checking logic 2019-10-10 12:07:54 +05:30
Humble Chirammal
ed477e1ba1 At present, the request timeout of sidecars are at the 60s and this is a request to increase
this time out value to 150s or higher. The higher timeout value can help to reduce the
load of our backend ceph cluster and also can avoid throttling issues at sidecars to an extent.

Fix# #602

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
(cherry picked from commit 1efdf14ac5)
2019-10-09 09:49:49 +00:00
Ilya Dryomov
1a81316ca7 Format ext4 with lazy_journal_init
Skip zeroing of the journal on freshly created images.  As only dynamic
PVs are supported, it is fine to assume that existingFormat == "" image
has never been mapped and written to before.

lazy_itable_init is enabled by default, passing it for consistency with
lazy_journal_init.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 9a61fa0c0a)
2019-10-04 15:48:49 +00:00
Madhu Rajanna
4c87c5712b update mergify for auto merging
update rules to auto merge in master branch

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 3784268dde)
2019-10-01 21:27:57 +05:30
Daniel-Pivonka
d979e7fa24 Change default csi liveness ports to ones less common
Signed-off-by: Daniel-Pivonka <dpivonka@redhat.com>
(cherry picked from commit cd52798a51)
2019-10-01 15:49:37 +00:00
wilmardo
ed193f0026 fix: add POD_NAMESPACE to RBD provisioner deployments
Signed-off-by: wilmardo <info@wilmardenouden.nl>
(cherry picked from commit abdadef8bc)
2019-09-30 11:55:58 +00:00
Madhu Rajanna
86da6c1d44 if there are changes requested dont merge PR
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 0b261e2819)
2019-09-30 10:48:46 +00:00
Madhu Rajanna
38a64d0b84 Replace ' with " in mergify.yaml
as per the examples rules in
https://doc.mergify.io/examples.html, string are
surrounded  by `""`, it better to follow same
format here also.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit ed364cf6ea)
2019-09-30 10:48:46 +00:00
Madhu Rajanna
39d30ef77a Add mergify rule to auto merge backported PR
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 136d81b736)
2019-09-30 10:48:46 +00:00
Madhu Rajanna
454394322a Add a check for nil secrets
Improve the error message if
secrets are not provided in request

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit b8568a5bb9)
2019-09-27 18:05:33 +05:30
Madhu Rajanna
756a650cd1 Remove rootfs from rbd provisioner pod
rootfs dependency was removed from rbd
by removing support for `nsenter`, This
PR removed the `/` mount from provisioner

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 3d0cba1931)
2019-09-27 18:04:00 +05:30
wilmardo
e5904485a3 refactor: Merge 1.13 and 1.14 Helm charts and improve charts
Signed-off-by: wilmardo <info@wilmardenouden.nl>
(cherry picked from commit afda225d75)
2019-09-27 10:44:17 +00:00
Madhu Rajanna
68a276677e change v1.2.1 to v1.2-canary
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-27 09:53:07 +05:30
Madhu Rajanna
ecac134c38 Added E2E for rbd nodeplugin restart
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 3f8a073258)
2019-09-25 15:40:51 +05:30
Madhu Rajanna
74852cf230 deprecate containerized flag and remove nsenter
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit d2fd76a9a5)
2019-09-25 15:40:51 +05:30
Madhu Rajanna
64fd06825a tempate changes for containerized flag removal
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit e0264da49a)
2019-09-25 15:40:51 +05:30
Madhu Rajanna
c1e374fae7 Remove nsenter packages from vendor
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 0ff5026bbe)
2019-09-25 15:40:51 +05:30
Humble Chirammal
ccdb23297d We were defaulting to ext4 at first and then moved toxfs.
However further testing shows that, ext4 should be
the default or preferred fs for RBD devices.

This patch bring that change

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
(cherry picked from commit b44a81bdbc)
2019-09-25 14:17:19 +05:30
Humble Devassy Chirammal
a5896ba633
Merge pull request #636 from humblec/discard
Format RBD volumes with `nodiscard` formatting options.
2019-09-25 14:05:06 +05:30
Humble Devassy Chirammal
488050d573
Merge pull request #638 from Madhu-1/update-template
Update templates for 1.2.1
2019-09-25 13:56:00 +05:30
Madhu Rajanna
80447caea3 update readme with 1.2.1 details
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-25 10:22:31 +05:30
Madhu Rajanna
d767d0fa48 update cephcsi image version to 1.2.1
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-25 10:22:31 +05:30
Humble Devassy Chirammal
f9dc39973f
Merge pull request #637 from Madhu-1/change-img-tag
Push cephcsi 1.2.1 image
2019-09-25 10:21:38 +05:30
Madhu Rajanna
f535e503c2 Push cephcsi 1.2.1 image
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-25 09:54:18 +05:30
Humble Chirammal
d1c8cce659 Format RBD volumes with nodiscard formatting options.
Currently rbd CSI plugin uses formatAndMount of
mount.SafeFormatAndMount. This does not allow to pass or use
specific formatting arguments with it. This patch introduce
RBD specific formatting options with both xfs and ext4,
for example: -E no-discard with ext4 and -k option with
XFS to boost formatting performance of RBD device.

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
(cherry picked from commit 0e6617e1ff)
2019-09-24 14:41:36 +05:30
Madhu Rajanna
61db816a89 connect to provisioner socket
Fixes: #619

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit e2890a27ff)
2019-09-23 13:16:17 +00:00
Madhu Rajanna
1ae09be924 Change the logic of locking
if any on going opearation is seen,we
have to return Abort error message

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 6aac399075)
2019-09-23 12:38:51 +00:00
Madhu Rajanna
cbd42a2181 use rook v1.1.0 in E2E testing
rook master is not good enough to
depend on for E2E testing, swithing to v1.1.0
for E2E

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 18151e9ca8)
2019-09-23 09:10:18 +00:00
Madhu Rajanna
e3e8afc0d8 push v1.2-canary image
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-12 07:16:35 +00:00
Madhu Rajanna
c420ee6de9
Merge pull request #596 from Madhu-1/fix-img-push
Fix readme
2019-09-06 22:39:06 +05:30
Madhu Rajanna
7bcb33a2e9 Fix readme
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-06 22:18:32 +05:30
Humble Devassy Chirammal
404a272e82
Merge pull request #590 from Madhu-1/update-img
Prepare for v1.2.0
2019-09-06 22:11:39 +05:30
Madhu Rajanna
51e4469878 update canary to v1.2.0 in helm chat
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-06 22:08:49 +05:30
Madhu Rajanna
9168a5ee09 update canary to v1.2.0 to push cephcsi image
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2019-09-06 22:08:49 +05:30