Repository navigation
Add optional mounts - #83
Conversation
When defining a list of mounts, you can now specify an 'optional_mount'. These are checked in the apptainer_entrypoint to see if the path exists. If not, then a warning is sent to stderr and the mount is excluded from the apptainer mount list.
ptsOSL
left a comment
There was a problem hiding this comment.
I think the premise is good, just a few details to improve on
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #83 +/- ##
==========================================
- Coverage 99.48% 99.39% -0.10%
==========================================
Files 27 27
Lines 978 993 +15
==========================================
+ Hits 973 987 +14
- Misses 5 6 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
ptsOSL
left a comment
There was a problem hiding this comment.
Thats a nice and easy way to prioritise the local entrypoint mounts. I am happy with these changes. Is it worth adding a test to check that the local entrypoint mounts are prioritised?
The solution in apptainer_app.py removed entries from the mounts list, which would affect all defined entrypoints. This solution ensures that each entrypoints mounts are resolved independently from each other
5582a4c to
621ddc7
Compare
621ddc7 to
31dad3b
Compare
MJGaughran
left a comment
There was a problem hiding this comment.
I only noticed a minor mistake in the comment. Otherwise, how exactly did you verify that this is backwards-compatible with the existing configuration & deployment?
Adds optional mounts.
When an optional mount is invalid, it will exclude it from the mount list so it does not cause an error. This handles all types of mounting syntax, such as:
e.g. Using the options:
As part of this PR, we decided to make it so that the entrypoint mounts always take precedence over the global. This allows someone to define a path as 'required' globally, but 'optional' for specific entrypoints. (and vice versa).