Skip to content

[v2] Support namespaced ProviderConfigs #6458

@jbw976

Description

@jbw976

(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 scoped
  • ProviderConfig.aws.m.crossplane.io - Namespaced
  • ProviderConfig.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:

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

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions