Mellanox / ci-demo

Apache License 2.0
2 stars 20 forks source link

add support for nfs_volumes #67

Closed andrii-holovchenko closed 2 years ago

andrii-holovchenko commented 2 years ago

Allow to map nfs share inside a pod

Signed-off-by: Andrii Holovchenko andriih@nvidia.com

mike-dubman commented 2 years ago

what is a use-case for this feature? why mapped volumes does not deliver same effect?

andrii-holovchenko commented 2 years ago

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

mike-dubman commented 2 years ago

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

andrii-holovchenko commented 2 years ago

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

It will be applied in pipeline_start and pipeline_stop sections using runK8() function. Please see: https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L1400-L1402 https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L716-L726

mike-dubman commented 2 years ago

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

It will be applied in pipeline_start and pipeline_stop sections using runK8() function. Please see:

https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L1400-L1402

https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L716-L726

but what it does - adds mapping into listV that is applied as maps to container what does mount $remote_host:$remote_path $local_path ?

andrii-holovchenko commented 2 years ago

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

@mike-dubman according to @yshestakov - soon we'll transfer some k8s servers to new area and MTR mounts will not be available there using autofs, so we need to add support of direct NFS mount to use them

i see. can we put direct mount into on_start and on_stop sections?

It will be applied in pipeline_start and pipeline_stop sections using runK8() function. Please see: https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L1400-L1402

https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L716-L726

but what it does - adds mapping into listV that is applied as maps to container what does mount $remote_host:$remote_path $local_path ?

nfsVolume() function inside parseListNfsV():

https://github.com/Mellanox/ci-demo/blob/2344900a40c0393763e920f55a57e5a8f94c9883/src/com/mellanox/cicd/Matrix.groovy#L695-L698