When tasks are run in apptainer, the container's launch command is extended with a bunch of -B options to mount all the local data providers found on the target system. This means sometimes, we mount folders that are not even necessary for the job.
An example of that, as seen in the .science.TOOL script, was this long line:
A better mechanism would be to only mount a folder for a DP if there is at least one input file for the task on that particular DP.
We could also consider mounting these local DPs in "read-only" mode. Tasks aren't supposed to modify any of their input files, generally. There is a flag at the ToolConfig level that indicates this anyway, so the value of the flag coudl be used to determine if we mount them read-only.
When tasks are run in apptainer, the container's launch command is extended with a bunch of
-B
options to mount all the local data providers found on the target system. This means sometimes, we mount folders that are not even necessary for the job.An example of that, as seen in the .science.TOOL script, was this long line:
(reformatted on multiple lines for clarity).
A better mechanism would be to only mount a folder for a DP if there is at least one input file for the task on that particular DP.
We could also consider mounting these local DPs in "read-only" mode. Tasks aren't supposed to modify any of their input files, generally. There is a flag at the ToolConfig level that indicates this anyway, so the value of the flag coudl be used to determine if we mount them read-only.