Skip to content

Conversation

prankulmahajan
Copy link
Member

As per VPC file csi driver use case, we require the k8s to update the ownership of volume via fsGroup in case the volume is used by an application running as non root.

As per VPC file csi driver use case, we require the k8s to update the ownership of volume via fsGroup in case the volume is used by an application running as non root.
@contsto
Copy link

contsto commented Feb 5, 2024

👍 Coverage increased from [%] to [81.8125%]

Copy link
Member

@ambiknai ambiknai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@prankulmahajan Is this capability added in code?

CSI drivers that support this feature should advertise the [VOLUME_MOUNT_GROUP](https://github.com/container-storage-interface/spec/blob/master/spec.md#nodegetcapabilities) node capability.

After recognizing this information, the kubelet passes the fsGroup information to the CSI driver during pod startup. This is done through the [NodeStageVolumeRequest](https://github.com/container-storage-interface/spec/blob/v1.7.0/spec.md#nodestagevolume) and [NodePublishVolumeRequest](https://github.com/container-storage-interface/spec/blob/v1.7.0/spec.md#nodepublishvolume) CSI calls.

@prankulmahajan
Copy link
Member Author

@prankulmahajan Is this capability added in code?

CSI drivers that support this feature should advertise the [VOLUME_MOUNT_GROUP](https://github.com/container-storage-interface/spec/blob/master/spec.md#nodegetcapabilities) node capability.

After recognizing this information, the kubelet passes the fsGroup information to the CSI driver during pod startup. This is done through the [NodeStageVolumeRequest](https://github.com/container-storage-interface/spec/blob/v1.7.0/spec.md#nodestagevolume) and [NodePublishVolumeRequest](https://github.com/container-storage-interface/spec/blob/v1.7.0/spec.md#nodepublishvolume) CSI calls.

This capilility was added for drivers which support option to pass fsGroup as mount option during mount. But in IBM case that is not there. So we cannot delegate the fsGroup changes to CSI driver but rather have to rely on kubelet to do that us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants