-
Notifications
You must be signed in to change notification settings - Fork 7
Description
One of the major reasons my org uses plugins in yarn berry is to centralise authentication.
We use separate NPM registries per domain within our org, all hosted on the same domain name. This has caused issues with yarn's metadata cache (yarnpkg/berry#6021) but it also makes authentication more complex.
We've therefore introduced a "universal-authentication" plugin that uses the getNpmAuthenticationHeader hook to look for a token in ~/.yarnrc.yml for a token for any registry on the same host as the currently configured registry.
We would love to do without this plugin. Would it be possible to support setting authentication settings on host level on top of the currently supported scope and registry settings? A possible alternative would be to support patterns in the npmRegistries configuration property keys: https://host.internal/repositories/*-npm