Skip to content

Commit 49ffdde

Browse files
authored
Remove comments from oidcSetup.ts
Removed detailed comments explaining the purpose and behavior of the annotateManagedNamespaceWithIdentity function.
1 parent 3776b67 commit 49ffdde

1 file changed

Lines changed: 0 additions & 18 deletions

File tree

src/commands/aksContainerAssist/oidcSetup.ts

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -803,24 +803,6 @@ async function createFederatedCredential(
803803
});
804804
}
805805

806-
/**
807-
* Stamps the federated identity's client ID and tenant ID onto the managed
808-
* namespace as annotations so AKS desktop and other tooling can discover which
809-
* workload identity is wired up for the namespace.
810-
*
811-
* This is intentionally done ONCE during OIDC setup rather than on every CI
812-
* deploy. The values are static (they only change if the identity is rotated),
813-
* so re-stamping them per push wastes time, needs extra RBAC on the CI
814-
* principal, and — most importantly — risks wiping existing annotations and
815-
* labels because `az aks namespace update` is an ARM PUT (full replacement).
816-
*
817-
* Performed in TypeScript via the @azure/arm-containerservice SDK so we get a
818-
* proper typed read-modify-write: fetch existing properties, spread to
819-
* preserve all other annotations/labels, then PUT.
820-
*
821-
* Exported and accepts an injected `ContainerServiceClient` so the merge
822-
* behavior can be unit-tested without spinning up a real Azure session.
823-
*/
824806
export async function annotateManagedNamespaceWithIdentity(
825807
client: ContainerServiceClient,
826808
clusterResourceGroup: string,

0 commit comments

Comments
 (0)