-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
(broken out from #6280)
Today all ProviderConfigs are cluster scoped. With namespaced MRs, I expect folks would benefit from both cluster scoped and namespaced ProviderConfigs. The way you could create a 'global default' ProviderConfig for all namespaces at the cluster scoped, or specific ProviderConfigs limited to one namespace.
In the v2 compatible preview of provider-upjet-aws, we do have namespaced ProviderConfig types, but they are not finalized and no code is actually using them yet.
The final types should look like this, similar to how we approached Usage.protection.crossplane.io:
ClusterProviderConfig.aws.m.crossplane.io- Cluster scopedProviderConfig.aws.m.crossplane.io- NamespacedProviderConfig.aws.upbound.io- Legacy cluster scoped
This issue depends on #6457, e.g. for "MRs should be able to reference either cluster scoped or namespaced ProviderConfigs via spec.providerConfigRef".
There are a few places in the upjet provider code bases that need to be updated to be aware of namespaced ProviderConfigs:
- clients.SelectTerraformSetup
- clients.provider_config.go has lots of code still using cluster scoped ProviderConfigs
- (there are probably others too...)
We can consider adding an internal ProviderConfig type that the clients use, and converting to that type from the namespaced/cluster types as needed. This idea needs more thought and exploration.
ProviderConfig usage tracking likely needs to be updated to support namespaced resources as well.
Metadata
Metadata
Assignees
Type
Projects
Status