Open yavor-atanasov opened 1 year ago
The module_enable
option doesn't make much sense on the command line. The options you pick at the "chroot initialization" phase are baked into the cache, any other subsequent use of these has no effect. The option is not documented, and is obsoleted by module_setup_commands
(we should raise a proper warning).
Anyway, if you need to specify array on commandline, you have set the same value multiple times, and if you need array with a single item - just specify the first item as empty string, e.g. --config-opts module_enable= --config-opts module_enable=nodejs:18
.
The options you pick at the "chroot initialization" phase are baked into the cache, any other subsequent use of these has no effect
I realised this as I played around with it a bit more. It's a shame, I think being able to trigger different builds with the same root config but vary the enabled yum modules per build would be a great feature. Otherwise, like you say, there's no point in exposing those options on the command line. Also, I'm not sure how you even provide values to the module_setup_commands
via the command line given it needs to translate to a list of tuples.
I guess our best bet is to just create separate configurations per build, which will result in multiple root caches (even though they will only differ on the set of enabled modules)
Alternatively, we could implement a runtime knob for working with modules (so that modules are enabled/installed/... post-init time)? The popularity of modularity is decreasing though; Fedora demodularizes, not sure what's the future to invest too much into it. Would you mind submitting a patch?
Short description of the problem
Specifying
module_enable
config option via the command line seems to cause an error.Output of
rpm -q mock
Steps to reproduce issue
This is the command I'm running. The contents of the specfile and the sources is irrelevant, because mock fails when it tries to setup the build environment
The error this produces is:
I can see why the error happens, but I can't work out how I'm supposed to specify this option via the command line. I can specify this option fine in a config file like this and it gets interpreted as python:
I can't see any examples of this in any docs. Any help is much appreciated