Summary
Maybe this is already possible, but it seems that -C scopes are always read-only (ImmutableConfigScope), so I haven't found a way to provide a custom writeable scope.
Rationale
On CI machines that are not containerized (e.g., macOS, Windows), ensuring the CI jobs stay in a specific directory is key to keeping machines "clean". I'd like to tell Spack "never write to ~/.spack" and have it write its configurations elsewhere. Rewriting HOME is a sledgehammer that may have other unintended side effects (e.g., other tools not finding their configurations which are treated as read-only).
Description
Some way to add in a writeable scope at a higher precedence level than the user store. Maybe --config-scope-write or something?
Additional information
$ bin/spack --version
0.16.3-4938-e7c7f44bb6
General information
Summary
Maybe this is already possible, but it seems that
-Cscopes are always read-only (ImmutableConfigScope), so I haven't found a way to provide a custom writeable scope.Rationale
On CI machines that are not containerized (e.g., macOS, Windows), ensuring the CI jobs stay in a specific directory is key to keeping machines "clean". I'd like to tell Spack "never write to
~/.spack" and have it write its configurations elsewhere. RewritingHOMEis a sledgehammer that may have other unintended side effects (e.g., other tools not finding their configurations which are treated as read-only).Description
Some way to add in a writeable scope at a higher precedence level than the user store. Maybe
--config-scope-writeor something?Additional information
General information
spack --versionand reported the version of Spack