Replies: 1 comment 6 replies
-
Thank you for the question and welcome! Awesome to see we are having another potential Azure Linux config contributor/maintainer!
Can you try to set the mentioned options, ie.
Sure! If the above doesn't help, we can have a new option. Please keep the default behavior withouth changes, and document the new options you add. |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Are there any supported methods of requesting
mock
skip copying/etc/pki-ca-trust/source
(and/usr/share/pki/ca-trust-source
) into the root environment? I'm expecting the answer to be "no" based on my read of the code, so my immediate follow-up question would be: are you open to a contribution to add a new config option to allow opting out of the copy?(I see that
copy_certs()
unconditionally copies these directories into the root, and this is invoked in each call to_PackageManager.initialize()
. I do see precedent for some configuration in this area, viassl_ca_bundle_path
andssl_extra_certs
config options that can be configured via.cfg
file.)As context -- I'm running into errors building certain packages with
mock
on an Azure Linux 3.0 host system. (As an aside, I work on the Azure Linux project and it's been great to see the recently added support for Azure Linux! I'd love to figure out how to contribute toward that support in the future.) On Azure Linux 3.0, theca-certificates-shared
package (depended on byca-certificates
) installs a symlink under/etc/pki/ca-trust/source
("blocklist"
)--and a similar one under/usr/share/pki/ca-trust-source
. Whenmock
creates and initializes an Azure Linux 3.0-based root, this package doesn't need to be installed into the root, butcopy_certs()
will copy in these dirs. During the copy operation, the (dir) symlink turns into a non-symlink directory in the root. When a package build ends up requiringca-certificates
(and thusca-certificates-shared
) to be installed into the root, the install transaction fails with a cpio error because the copied directory conflicts withdnf
trying to install a symlink.I've spoken with maintainers of the
ca-certificates-shared
package in Azure Linux 3.0, and there's agreement to remove the symlink for the next major release of the distro, but it looks like we'll need to live with it for 3.0.More broadly, I can see an argument for a build scenario in which the root is either disconnected from the network (and doesn't need these certs), or network-enabled but wants to be more "narrowly trusting" than the host system. In these cases, I could see general value for such a policy option to allow a caller to disable this copying functionality.
Either way, I appreciate any help / pointers / feedback in advance. If there is openness to a new config option, I'm happy to draft a PR and work on the contribution. If there are concerns about the idea of adding such an option, it would be great for any pointers on alternative options for avoiding the specific challenges we're running into.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions