Open antoinetran opened 1 month ago
I think this is already implemented through https://github.com/interTwin-eu/interlink-slurm-plugin/blob/main/examples/config/SlurmConfig.yaml#L7C1-L7C18 . Testing it...
The test failed. The prefix did nothing.
In fact, the SingularityPrefix
is not a prefix added to image. After looking in the code, I can see that:
SingularityPrefix
nor the slurm-job.vk.io/singularity-commands
seems to be used, these variables are not used anywhereMy proposition is to add a SingularityImagePrefix
in the slurm configuration file and use it in the container creation.
Yeah, I agree. This was overlooked and never used I suspect.
Workaround: this is already implemented and tested in main branch. Add an annotation:
apiVersion: batch/v1
kind: Job
metadata:
name: helloworld
spec:
template:
metadata:
labels:
app: helloworld
annotations:
slurm-job.vk.io/image-root: "docker://"
Then InterLink will add "docker://" as expected for singularity. Currently we have to do that for each pod.
Short Description of the issue
When applying an image like alpine, the singularity fails to run because it does not know it is a docker image.
Environment
Steps to reproduce
Logs, stacktrace, or other symptoms
Summary of proposed changes
Allow to configure Slurm plugin to add, for all image: if it does not start with
/
(meaning an absolute path to a local image), then add a prefix likedocker://
ororas://
or nothing if the prefix configuration is absent.