The AWSFederatedAccountAccess CR creates an instance of an AWSFederatedRole in AWS and allows the target IAM account to assume its role.
apiVersion: aws.managed.openshift.io/v1alpha1
kind: AWSFederatedAccountAccess
metadata:
name: example-account-access
namespace: aws-account-operator
spec:
awsCustomerCredentialSecret:
name: {Name for secret with osdManagedAdmin credentials}
namespace: {Namespace for the secret with osdManagedAdmin credentials}
externalCustomerAWSIAMARN: arn:aws:iam::${EXTERNAL_AWS_ACCOUNT_ID}:user/${EXTERNAL_AWS_IAM_USER}
awsFederatedRole:
name: {Name of desired AWSFederatedRole}
namespace: aws-account-operatorThe AWSFederatedAccountAccess controller is triggered when an AccountClaim is created in any namespace. It is responsible for the following behaviors:
- Ensures the requested
AWSFederatedRoleexists. - Converts the
AWSFederatedRolespec into an AWSPolicyDoc. - Creates a unique AWS
Rolein the AWS containing the OSD cluster using theAWSFederatedRoledefinition. - Creates a unique AWS
Policyif theAWSFederatedRolehasawsCustomPolicydefined and attaches it to the Role. - Attaches any specified AWS Managed Policies to the
Role. - Keeps the AWS
Policyin sync with the backingAWSFederatedRole.
None
spec:
awsCustomerCredentialSecret:
name: {Name for secret with osdManagedAdmin credentials}
namespace: {Namespace for the secret with osdManagedAdmin credentials}
externalCustomerAWSIAMARN: arn:aws:iam::${EXTERNAL_AWS_ACCOUNT_ID}:user/${EXTERNAL_AWS_IAM_USER}
awsFederatedRole:
name: {Name of desired AWSFederatedRole}
namespace: aws-account-operatorawsCustomerCredentialSecretis the secret reference for the osdManagedAdmin IAM user in the AWS account where OSD is installedexternalCustomerAWSIAMARNis the AWS ARN for the desired IAM user that will use the AWS role when created. This should be in an AWS account external to the one where OSD is installed.awsFederatedRoleis the reference to the targetAWSFederatedRoleCR to create an instance of.
status:
conditions:
- lastProbeTime: {Time Stamp}
lastTransitionTime: {Time Stamp}
message: Account Access Ready
reason: Ready
status: "True"
type: Ready
consoleURL: https://signin.aws.amazon.com/switchrole?account=701718415138&roleName=network-mgmt-5dhkmd
state: Readyconditionsindicates the states theAWSFederatedAccountAccesshad and supporting detailsconsoleURLis a generated URL that directly allows the targeted IAM user to access the AWSRolestateis the current state of the CR
None