From ab73ed1aa63ae6eb5bbc02e466353a211da82a88 Mon Sep 17 00:00:00 2001 From: Gautier Dagan Date: Tue, 26 Mar 2024 14:05:33 +0000 Subject: [PATCH] document nfs usage --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index cd64179..ee19074 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,23 @@ print(job.generate_yaml()) job.run() ``` +#### NFS partition + +You can mount an NFS partition to the Kubernetes Job by specifying the NFS server address, path, and mount options. + +```python +from kubejobs.jobs import KubernetesJob + +job = KubernetesJob( + ... + volume_mounts={ + "nfs": {"mountPath": "/nfs", "server": "10.24.1.255", "path": "/"} + }, +) +``` +Note that both `server` and `path` are required fields for the NFS volume mount. + + ### create_jobs_for_experiments The create_jobs_for_experiments function allows you to create and run a series of Kubernetes Jobs for a list of commands. This can be helpful for running multiple experiments or tasks with different parameters in parallel.