deploy-on-aws
Skill8 starsChanged 41 days agoApache-2.0View on GitHub
Deploy applications to AWS via deploy.sh. Triggers on phrases like: deploy to AWS, deploy.sh, build me a deploy script, host on AWS, run this on AWS, AWS architecture, estimate AWS cost, generate infrastructure. Analyzes any codebase and deploys to optimal AWS services.
In this repository17 other files it gives its agents.
- AGENTSAGENTS.md
- amazon-bedrockSkill
- amazon-location-serviceSkill
- amazon-polly-generativeSkill
- aws-architecture-diagramSkill
- aws-diagram-htmlSkill
- aws-diagram-pngSkill
- aws-serverless-patternsSkill
- cdk-infrastructure-patternsSkill
- cognito-email-migrationSkill
- cognito-passkey-authSkill
- email-template-renderingSkill
- mcp-tool-discoverySkill
- personal-rules-managementSkill
- react-frontend-patternsSkill
- reinvent-stack-toolkitSkill
- testing-patternsSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. About 0 are common, 6 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 20
Generate: - Write IaC code with security defaults applied
- Very specific: line 21
Quality Gate: - Run the Pre-Deployment Quality Gate from development-workflow.md: lint (zero warnings), build (zero warnings), unit tests …
- Very specific: line 22
Deploy: - Run security checks (cdk-nag), then execute via deploy.sh
- Distinctive: line 26
Default to dev-sized (cost-conscious: small instance sizes, minimal redundancy, single-AZ) unless user says "production-ready".
- Very specific: line 30
Use the unified AWS MCP Server (aws-mcp-server, via mcp-proxy-for-aws) for all AWS interactions.
- Very specific: line 39
Every project ships a deploy.sh at the root following the full contract documented in steering/aws-deploy-contract.md.
- Very specific: line 59
When deploy.sh runs verbose tools (cdk synth, cdk deploy, npm run build), use the side channels so the user sees full progress in the TUI …
- Very specific: line 103
Always fall back gracefully: ${AGENT_DISPLAY_OUT:-/dev/stderr} works when not invoked by Kiro.
- Distinctive: line 108
Always show cost estimate before generating code
- Distinctive: line 110
Run IaC security scans (cdk-nag, cfn-nag) before deployment
- Distinctive: line 111
Don't ask "Lambda or Fargate?" — just pick the obvious one
- Distinctive: line 112
If genuinely ambiguous, then ask
- Very specific: line 113
Use AWS managed KMS keys (aws/service-name) over customer-managed unless there's a specific compliance requirement
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Deploy on AWS
Take any application and deploy it to AWS with minimal user decisions.
Philosophy
Minimize cognitive burden. User has code, wants it on AWS. Pick the most straightforward services. Don't ask questions with obvious answers.
Workflow
- Analyze - Scan codebase for framework, database, dependencies
- Recommend - Select AWS services, concisely explain rationale
- Estimate - Show monthly cost before proceeding
- Generate - Write IaC code with security defaults applied
- Quality Gate - Run the Pre-Deployment Quality Gate from
development-workflow.md: lint (zero warnings), build (zero warnings), unit tests (≥90% coverage), Playwright E2E (target 100%), no deprecation notices, no critical/high vulnerabilities - Deploy - Run security checks (cdk-nag), then execute via
deploy.sh
Defaults
Default to dev-sized (cost-conscious: small instance sizes, minimal redundancy, single-AZ) unless user says "production-ready".
MCP Server Usage (AWS Agent Toolkit)
Use the unified AWS MCP Server (aws-mcp-server, via mcp-proxy-for-aws) for all AWS interactions. Resolve the actual callable tool name via tool_search before invoking any of these — see steering/aws-agent-toolkit.md → "Resolving the correct tool name" if a call fails with "Tool is not available":
- Architecture decisions: the AWS docs-search tool (
search_documentation, filter byagent_skills) and the skill-retrieval tool (retrieve_skill) to load curated guidance before designing - API knowledge: the AWS docs-search tool (topic
current_awarenessorreference_documentation) to verify the exact API/CLI syntax — never guess. There is no dedicated "suggest commands" tool; docs search is the current path for this. - Cost estimates: the sandboxed-Python tool (
run_script) to invoke the Pricing API or Cost Explorer directly — this is the only AWS-API-call tool now (call_awswas removed Aug 31, 2026). Always present costs before generating IaC so the user can adjust before committing - IaC validation: the sandboxed-Python tool (
run_script) for sandboxed Python checks (e.g., synth a CDK stack and inspect the template)
deploy.sh Contract (MANDATORY)
Every project ships a deploy.sh at the root following the full contract documented in steering/aws-deploy-contract.md. Reference template: skills/deploy-on-aws/references/deploy.sh.template.
Required flags:
| Flag | Purpose |
--profile <name> | AWS profile (defaults to default) |
--domain <fqdn> | Custom domain (saved per profile, recalled next run) |
--delete | Tear down stack AND deep-clean orphans (S3, log groups, ACM certs, etc.) |
-y / --yes | Auto-confirm — skip every prompt |
-h / --help | Show usage |
Per-profile state lives in .deploy-state.json (gitignored). When the user re-runs deploy.sh without --domain, the value saved for the current profile is recalled. Add .deploy-state.json to .gitignore.
Multi-project safety: --delete discovers resources by the project=<name> tag (NOT by name prefix). Resources without that tag are never touched, so sibling projects in the same account are safe. The CDKToolkit bootstrap stack is never destroyed by deploy.sh --delete.
-y is intended for CI-like or fast-iteration usage. Without -y, the script prompts at every destructive step.
Use Agent Output Side Channels (Kiro CLI 2.3.0+)
When deploy.sh runs verbose tools (cdk synth, cdk deploy, npm run build), use the side channels so the user sees full progress in the TUI while the agent's context stays lean (only summary lines):
#!/usr/bin/env bash
# deploy.sh — uses Kiro CLI side channels when present
set -euo pipefail
# Detect side channels (only set when invoked by Kiro agent)
DISPLAY_OUT="${AGENT_DISPLAY_OUT:-/dev/stderr}"
CONTEXT_OUT="${AGENT_CONTEXT_OUT:-/dev/null}"
# Verbose: stream to user TUI but NOT to agent context
echo "==> cdk synth"
cdk synth --profile "$PROFILE" 2>&1 | tee "$DISPLAY_OUT" > /dev/null
echo "==> cdk deploy"
cdk deploy --all --profile "$PROFILE" --require-approval never 2>&1 | tee "$DISPLAY_OUT" > /dev/null
# Concise: summary the agent SHOULD see (via agent_notes)
STACK_NAME=$(cdk list --profile "$PROFILE" | head -1)
ENDPOINT=$(aws cloudformation describe-stacks \
--stack-name "$STACK_NAME" --profile "$PROFILE" \
--query 'Stacks[0].Outputs[?OutputKey==`ApiEndpoint`].OutputValue' \
--output text)
cat <<EOF > "$CONTEXT_OUT"
Stack: $STACK_NAME — DEPLOYED
Profile: $PROFILE
Region: ${AWS_REGION:-us-east-1}
API endpoint: $ENDPOINT
EOF
# Plain stdout — captured normally, agent sees this too
echo "✓ Deploy complete"How the channels behave:
| Channel | User TUI | Agent context | Use for |
| stdout (default) | shown | included | brief summary lines (one-liners) |
$AGENT_DISPLAY_OUT | shown | NOT included | verbose logs (cdk synth, build output) |
$AGENT_CONTEXT_OUT | shown | included as agent_notes | structured facts the agent needs (stack name, endpoint URL, status) |
Always fall back gracefully: ${AGENT_DISPLAY_OUT:-/dev/stderr} works when not invoked by Kiro.
Principles
- Concisely explain why each service was chosen
- Always show cost estimate before generating code
- Apply security defaults automatically (encryption, private subnets, least privilege)
- Run IaC security scans (cdk-nag, cfn-nag) before deployment
- Don't ask "Lambda or Fargate?" — just pick the obvious one
- If genuinely ambiguous, then ask
- Use AWS managed KMS keys (
aws/service-name) over customer-managed unless there's a specific compliance requirement
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

