ai-governance
Generate and enforce policy gates for AI coding agents (Copilot, Claude Code) — real-time session hooks that deny protected-path…
Manage AWS profiles for MCP servers — discover SSO, Granted and role-chain profiles, check authentication with STS, switch configured profiles, and scan AWS Organization accounts. TTL is unknown unless the user shares an expiry timestamp without credentials.
Claude Code
$ npx -y skills add nitinjain999/platform-skills --skill aws-profile --agent claude-code
Codex
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a codex -y
Cursor
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a cursor -y
Gemini CLI
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a gemini-cli -y
GitHub Copilot
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a github-copilot -y
OpenCode
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a opencode -y
Windsurf
$ npx skills add nitinjain999/platform-skills --skill aws-profile -a windsurf -y
name: aws-profile description: Manage AWS profiles for MCP servers — discover SSO, Granted and role-chain profiles, check authentication with STS, switch configured profiles, and scan AWS Organization accounts. TTL is unknown unless the user shares an expiry timestamp without credentials. argument-hint: "[discover|status|switch <profile>|login <profile>|org-scan] [flags]" title: "AWS Profile Command" sidebar_label: "aws-profile" custom_edit_url: null
Manage AWS profiles for MCP server configurations across VS Code (GitHub Copilot) and Claude Code.
Reference: `references/aws-mcp-profiles.md`
List profiles with `aws configure list-profiles`. Read only these non-secret settings with `aws configure get <key> --profile <profile>`: `sso_session`, `sso_start_url`, `sso_region`, `sso_account_id`, `sso_role_name`, `role_arn`, `source_profile`, `region`, `granted_sso_account_id`, `granted_sso_role_name`. A missing setting is normal. Never retrieve access keys, session tokens, raw config files or credential caches, or execute `credential_process` to inspect its output. Let the AWS CLI handle authentication for the selected profile.
The AWS CLI continues to use its native credential chain, including `credential_process`. Keep the SSO, Granted and role-chain authentication setup guidance in `references/aws-mcp-profiles.md`.
For TTL, use only a profile-specific expiration timestamp the user has shared without credentials. Otherwise display `unknown`; successful authentication does not establish an expiry time. Parse MCP config files locally and return only server names, paths, `AWS_PROFILE` and `AWS_REGION`, since other fields can contain secrets. Do not print entire config files or diffs of unrelated fields.
---
When invoked with no arguments, ask before proceeding:
**Q1 — Mode?**
What do you need? 1. discover — list AWS profiles with type, account ID, env tag, and expiry when shared 2. status — show configured MCP profiles and check current authentication 3. switch — update MCP config files to use a different profile 4. login — authenticate and refresh credentials for a specific profile 5. org-scan — list all AWS Organization accounts and cross-reference with configured profiles Enter 1–5 or mode name:
**Q2 — Mode-specific follow-up** (one question, after mode is selected):
Then proceed into the relevant mode below.
---
List profiles and output a classified profile table with TTL where shared expiration metadata is available.
aws-profile discover [--type sso|assume-role|granted|static] [--env prod|staging|dev] [--account <id>] [--chain] [--expired]
**Output:**
Profile Type Account ID Env Tag Permission Set Expires TTL prod-platform-eu sso 123456789 prod PowerUser 14:32 UTC 47m ✓ staging-assume assume-role 456789123 staging - 13:58 UTC 13m ⚠ dev-sandbox granted 987654321 dev Developer 09:00 UTC EXPIRED ✗ security unknown 890123456 - - unknown unknown
The timestamp examples above assume the user supplied profile-specific expiry metadata. Without it, show `unknown` in both expiry columns.
**Steps:**
1. Run `aws configure list-profiles`, then query only the metadata keys in Credential boundary. Classify each profile by the settings present:
2. Calculate TTL only from shared expiration metadata for that profile. Do not read credential caches. Apply traffic-light TTL only when a timestamp is known:
3. Read `~/.aws-profile-tags.yaml` for env tags. If the file does not exist, generate a starter file:
# ~/.aws-profile-tags.yaml — edit to correct heuristic guesses prod-platform-eu: prod # detected: name contains 'prod' staging-assume: staging # detected: name contains 'stag' dev-sandbox: dev # detected: name contains 'dev' security: shared-services # detected: name contains 'security'
Print: `Generated ~/.aws-profile-tags.yaml — review and correct environment tags.`
4. Apply filters if flags provided. For `--expired`, list confirmed expired entries and report profiles with unknown TTL separately; unknown does not mean expired or healthy.
**With `--chain`** — show full role assumption chain for assumed-role profiles:
staging-assume role chain:
dev-sso (identity: 111111111)
└── assume → security-role (222222222)
└── assume → staging-platform (456789123) ← this profileFollow `source_profile` → `role_arn` links recursively with the metadata lookups above.
Reference: `references/aws-mcp-profiles.md` → Profile Type Detection, Credential Lifecycle
---
Show which profile each configured MCP server uses, authentication status and known credential TTL. Report refresh behaviour only when the configured method is known
A production-grade field handbook for platform, DevOps, SRE, and cloud engineers covering Kubernetes, Flux CD, Terraform, GitHub Actions, AWS, OPA/Rego, KEDA, Karpenter, supply chain security, Falco, observability, and more.
Generate and enforce policy gates for AI coding agents (Copilot, Claude Code) — real-time session hooks that deny protected-path…
Generate, convert, and maintain animated GitHub-safe Markdown documents with animated SVG diagrams. Covers four SVG patterns…
Structured guidance for AWS CloudFront distributions, WAF web ACLs, Lambda@Edge, CloudFront Functions, Firewall Manager…
Azure identity (Workload Identity, OIDC, Entra ID), resource tagging, AKS platform patterns, RBAC scoping, and…
Back up and restore Kubernetes workloads with Velero, and prove recovery works. Covers Velero on EKS via Flux (IRSA, S3 backup…
Design, run, and debug Chaos Engineering experiments on Kubernetes using Litmus Chaos v3 and Chaos Mesh v2. Covers fault…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.