aws configure sso: Set Up IAM Identity Center Login
Configure an IAM Identity Center (SSO) profile for interactive CLI login.
aws configure sso sets up a profile backed by IAM Identity Center, then aws sso login opens a browser to authenticate. It is excellent for local developer machines but is interactive, so CI should use OIDC role assumption instead of SSO.
Common flags
--profile NAME- name the SSO-backed profile--use-device-code- device-code flow for headless environmentsaws sso login --profile NAME- the companion command to authenticateaws sso logout- clear the cached SSO session
Example in CI
SSO is interactive; on a local machine you configure then log in. CI should prefer OIDC roles.
shell
aws configure sso --profile dev
aws sso login --profile devCommon errors in CI
- Error loading SSO Token: Token has expired - run aws sso login again
- The SSO session associated with this profile has expired - re-authenticate
- Interactive flow blocked in CI - SSO needs a browser; use OIDC role auth on runners instead
Key takeaways
- configure sso + sso login give interactive, browser-based CLI auth.
- It suits developer laptops, not CI - SSO is interactive by design.
- On CI runners, use GitHub OIDC role assumption instead of SSO.
Related guides
aws configure: Set Credentials and Region in CIaws configure sets AWS CLI credentials, region, and profiles. Learn the flags, a CI example, and why pipeline…
aws sts assume-role: Assume an IAM Role in CIaws sts assume-role returns temporary credentials for a target role, enabling cross-account deploys. Learn th…
aws sts get-caller-identity: Verify AWS Auth in CIaws sts get-caller-identity returns the account, user, and ARN for the current credentials. Use it to verify…