Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(eks): fargateCluster compatibility with AuthenticationMode.API (#…
…31267) ### Issue # (if applicable) This PR ensures the eks fargateCluster compatibility with `AuthenticationMode.API` Closes #30888 ### Reason for this change The FargateCluster assumes the authentication mode is always config map and create the podExectionRole mapping using `props.cluster.awsAuth.addRoleMapping()`. This won't work when authenticationMode is `API` because in this mode, config map is not supported and this statement would just fail. We need to add an conditional check, only when the cluster supports configmap will it run the addRoleMapping() statement. At this moment, the following authenticationMode would support configmap: 1. `undefined` 2. `CONFIG_MAP` 3. `API_AND_CONFIG_MAP` ### Description of changes ### Description of how you validated changes - [x] update the integ test - [x] manual deployments ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information