Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

capture instance config in jobspec for batch and alloc jobs #3679

Closed
grondo opened this issue May 25, 2021 · 3 comments
Closed

capture instance config in jobspec for batch and alloc jobs #3679

grondo opened this issue May 25, 2021 · 3 comments

Comments

@grondo
Copy link
Contributor

grondo commented May 25, 2021

From an offline discussion with @garlick:

Currently, the only way to specify a configuration for a subinstance run via flux mini alloc or flux mini batch is to pass a --config-path=PATH option down to the broker via the flux-mini --broker-opts option, e.g.

flux mini alloc --broker-opts="-c /home/grondo/myconf"

However, there are several drawbacks here:

  • the configuration under /home/grondo/myconf could be updated between job submission and job start
  • the configuration isn't captured along with the job record in any way, besides its path
  • small updates to the configuration can't be made without copying the config to a per-job directory

Instead of leaving the configuration to be read at runtime by the broker from the original filesystem path, the config should be read by flux mini batch or flux mini alloc and the resulting JSON representation placed into a well-known attribute in the jobspec. The job shell batch plugin can then write this configuration out to a temporary directory and pass it along to the brokers via the -c option.

A --setconf or similar option should also be added, which would amend the loaded (or default empty) configuration in the jobspec, allowing easy one-off updates to a more generic configuration placed on disk.

We have also previously discussed the use of "named" configuration paths. These could be specified by name on the flux mini command line, with the option of a "default" system or user provided named config that is used as a starting point when no configuration name is specified.

The system could provide a set of named configs, which could be overridden by users in a ~/.flux/configs directory or similar. As noted by @garlick, this would allow workflows to provide standard configs that could easily be selected by users.

@grondo
Copy link
Contributor Author

grondo commented May 26, 2023

cc: @trws - this is the issue I was thinking about in our recent slack discussion.

Some groundwork has been laid to get this done:

with that foundation laid, I expected to have basic support for embedding config under a well known key (may need an RFC 14 update) in jobspec, with a method for updating the config on the command line.

We then hope to add a way to established some kind of named configuration scheme (perhaps should open a separate issue on this) allowing users to easily select a starting config, e.g. --conf=node-exclusive.

@garlick
Copy link
Member

garlick commented Jan 8, 2024

Can we close this?

@grondo
Copy link
Contributor Author

grondo commented Jan 9, 2024

Oh yeah, sorry. This should have been closed by #5232

@grondo grondo closed this as completed Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants