Skip to content

Commit

Permalink
Document --container-env with overriding and entrypoint details.
Browse files Browse the repository at this point in the history
Documents #145 and #124.

Signed-off-by: Skander Moalla <[email protected]>
  • Loading branch information
skandermoalla authored and flx42 committed Jul 23, 2024
1 parent c74101b commit 42ef0d7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,13 @@ $ srun --help
--container-readonly [pyxis] make the container filesystem read-only

--container-env=NAME[,NAME...]
[pyxis] names of environment variables to preserve
from the host environment
[pyxis] names of environment variables to override
with the host environment and set at the entrypoint.
By default, all exported host environment variables
are set in the container after the entrypoint is run,
but their existing values in the image take precedence;
the variables specified with this flag are preserved
from the host and set before the entrypoint runs
```

## Examples
Expand Down
5 changes: 4 additions & 1 deletion args.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,10 @@ struct spank_option spank_opts[] =
{
"container-env",
"NAME[,NAME...]",
"[pyxis] names of environment variables to preserve from the host environment",
"[pyxis] names of environment variables to override with the host environment and set at the entrypoint."
"By default, all exported host environment variables are set in the container after the entrypoint is run,"
"but their existing values in the image take precedence;"
"the variables specified with this flag are preserved from the host and set before the entrypoint runs",
1, 0, spank_option_container_env
},
SPANK_OPTIONS_TABLE_END
Expand Down

0 comments on commit 42ef0d7

Please sign in to comment.