That change adds a type/multi-tenant/sub-clusters/lma/catalogue/oidc-utility-subcluster.yaml, a catalogue specific to the LMA subcluster, and which has the dex OIDC configuration specific for that subcluster. That setup required adding a bit more kustomize plumbing, so that at the site level, the LMA catalogues need to pull from the site-level target catalogues and the type-level lma catalogues.
In addition, that catalogue setup spreads out subcluster-specific port info across two places -- the shared subcluster-networking catalogue and a per-subcluster catalogue. It would be better to keep subcluster-networking as the single source of truth.
This issue is intended to streamline that complex inheritance by doing the following:
Take back out the lma site-level -> lma type-level catalogue inheritance, so that site-level sub-clusters/lma/catalogues only inherits resources from site-level target/catalogues
Add the subcluster-specific bit - the oidc_issuer field - to the shared subcluster-networking catalogue, as spec.lma.oidc_issuer (add one for spec.wordpress.oidc_issuer too while in there)
Remove the oidc-utility-subcluster.yaml catalogue from type-level sub-clusters/lma/catalogue/
Add a replacement rule to copy the oidc_issuer from the subcluster-networking catalogue into the shared utility-treasuremap catalogue that comes from the base function/treasuremap-base-catalogues. The rule should be added to type/multi-tenant/sub-clusters/lma/catalogue-replacements. Do the same for the wordpress subcluster catalogue replacements.
@shon-phand this one can actually be cancelled, it's no longer needed. The subcluster stuff in the multi-tenant type is deprecated. Sorry for the confusion.
This issue builds on top of work done in this change: https://review.opendev.org/c/airship/treasuremap/+/795527
That change adds a
type/multi-tenant/sub-clusters/lma/catalogue/oidc-utility-subcluster.yaml
, a catalogue specific to the LMA subcluster, and which has the dex OIDC configuration specific for that subcluster. That setup required adding a bit more kustomize plumbing, so that at the site level, the LMA catalogues need to pull from the site-level target catalogues and the type-level lma catalogues.In addition, that catalogue setup spreads out subcluster-specific port info across two places -- the shared
subcluster-networking
catalogue and a per-subcluster catalogue. It would be better to keepsubcluster-networking
as the single source of truth.This issue is intended to streamline that complex inheritance by doing the following:
sub-clusters/lma/catalogues
only inherits resources from site-leveltarget/catalogues
oidc_issuer
field - to the sharedsubcluster-networking
catalogue, asspec.lma.oidc_issuer
(add one forspec.wordpress.oidc_issuer
too while in there)oidc-utility-subcluster.yaml
catalogue from type-levelsub-clusters/lma/catalogue/
oidc_issuer
from thesubcluster-networking
catalogue into the sharedutility-treasuremap
catalogue that comes from the basefunction/treasuremap-base-catalogues
. The rule should be added totype/multi-tenant/sub-clusters/lma/catalogue-replacements
. Do the same for thewordpress
subcluster catalogue replacements.