Logo Eks Build

Eks Build

Tổ chức
aws-samples
eks-build

Dùng khi xây dựng cụm EKS. Tạo các dự án Terraform hoàn chỉnh, sẵn sàng cho môi trường production, với tùy chọn tích hợp GitOps của ArgoCD. Xử lý các ràng buộc theo môi trường: mạng cô lập, chỉ dùng VPC endpoint, proxy doanh nghiệp, registry container riêng và yêu cầu tuân thủ. Hỗ trợ 3 mô hình: Terraform toàn phần, ArgoCD+Terraform, ArgoCD+ACK/KRO. Bao gồm các module đã được xác thực, thứ tự webhook hai giai đoạn, IRSA/Pod Identity và hơn 29 cấu hình tiện ích bổ sung. Bạn có thể trả lời câu hỏi tương tác hoặc cung cấp YAML yêu cầu. Cũng dùng khi (1) tạo mã Terraform cho EKS từ đầu, (2) tạo tiện ích bổ sung EKS do GitOps quản lý bằng ArgoCD, (3) dựng khung dự án EKS với các ràng buộc tuân thủ, (4) triển khai thứ tự webhook hai giai đoạn cho tiện ích bổ sung EKS, (5) cấu hình IRSA hoặc Pod Identity cho khối lượng công việc EKS, (6) tạo ApplicationSet của ArgoCD để quản lý tiện ích bổ sung EKS hoặc (7) so sánh các mô hình triển khai để đưa ra quyết định thực hiện. Không dùng cho Amazon ECS (dùng ecs-build).

Add to TypingMind

Tổng quan

Nhà phát hànhaws-samples
Kho mãsample-apex-skills
Tên kỹ năngeks-build
Sao
90
Bản fork
20
Tệp đi kèm
8
Giấy phépMIT-0
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • 8 tệp đi kèm

    Các tập lệnh, mẫu và tài liệu tham khảo mà mô hình có thể đọc khi làm việc. Các tệp chỉ cho phép đọc và không bao giờ được thực thi.

  • Mã nguồn mở

    Được aws-samples công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Eks Build trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/aws-samples/sample-apex-skills/tree/main/skills/eks-build
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/aws-samples/sample-apex-skills.git /tmp/sample-apex-skills
mkdir -p .claude/skills
cp -r /tmp/sample-apex-skills/skills/eks-build .claude/skills/eks-build
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Eks Build trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Eks Build ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Eks Build với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

EKS Build

Generate complete, production-ready EKS infrastructure projects. All generated code is terraform apply-ready with zero manual fixups.

All generated Terraform code MUST follow the conventions from these companion skills:

  • terraform-skill -- resource block ordering, variable conventions, file organization, version constraints

When to Use

  • Generating EKS Terraform code from requirements (new project)
  • Scaffolding EKS infrastructure with air-gapped, proxy, or compliance constraints
  • Creating ArgoCD GitOps integration for EKS addon management
  • Implementing two-phase webhook ordering for eks-blueprints-addons
  • Configuring IRSA or Pod Identity for EKS workloads
  • Generating ArgoCD ApplicationSets for addon lifecycle
  • Creating Ralph loop validation configurations for EKS projects
  • Adding custom addons (Kyverno, Prisma, New Relic) to an EKS project
  • Choosing between or comparing deployment patterns (full Terraform vs ArgoCD+Terraform vs ArgoCD+ACK/KRO) for an actual build

Don't Use

  • Designing EKS architecture from requirements (use eks-design)
  • General Terraform module development or testing (use terraform-skill)
  • EKS cluster reconnaissance or discovery (use eks-recon)
  • EKS operational best practices reference (use eks-best-practices)
  • Amazon ECS builds of any kind (use ecs-build)

Internet Search Requirements

This skill generates code from scratch every time. Always search the internet for:

  • Latest versions of all addons, Helm charts, and Terraform modules before generating code -- never use hardcoded versions from cached knowledge
  • Latest EKS best practices when requirements don't exactly match existing patterns
  • Addon-specific configuration for addons not fully covered in existing patterns
  • Breaking changes in new versions of addons or Terraform modules
  • Pattern 2b: KRO, ACK, and Crossplane -- these evolve rapidly. Always search for latest RGD schema syntax, supported CRDs, ProviderConfig format, and known limitations

The references in this skill cover the most common scenarios. For anything beyond that, research first, then adapt.

Pattern Decision Matrix

Key distinction: All patterns use Terraform for the EKS cluster and VPC infrastructure. The patterns differ in how K8s addons and AWS addon resources are managed after the cluster exists.

FactorPattern 1: Full TerraformPattern 2a: ArgoCD + TF AWSPattern 2b: ArgoCD + K8s-native AWS
K8s addon managementTerraform (Helm releases)K8s-native (ArgoCD ApplicationSets)K8s-native (ArgoCD ApplicationSets)
AWS resources for addonsTerraform (IRSA roles, S3 buckets)Terraform for AWS IaC (IRSA roles, S3)K8s-native controller (ACK, Crossplane)
Deployment workflowCI/CD runs terraform applyFull GitOps -- ArgoCD reconciles from GitFull GitOps -- ArgoCD reconciles from Git
Drift detectionterraform plan (manual/scheduled)ArgoCD self-heal + terraform plan for AWSArgoCD self-heal + controller reconciliation
Terraform surface areaEverything (cluster + addons + AWS)Cluster + AWS resources (addons in ArgoCD)Cluster only (addons + AWS both in K8s)
Air-gapped supportBest (Terraform controls all images)Good (ECR mirrors + ArgoCD)Good (same as 2a)
StatusValidatedValidatedValidated

For detailed architecture, trade-offs, and selection criteria see references/pattern-guide.md.

Pattern 2a vs 2b -- The Defining Difference

The ONLY difference between 2a and 2b is WHO creates the AWS resources that addons need (S3 buckets, IAM roles, policies, Route53 zones):

Pattern 2aPattern 2b
Who creates AWS resources?Terraform (module "eks_blueprints_addons", aws_iam_role)K8s-native controller (ACK CRDs, Crossplane MRs)
Terraform surface areaCluster + IAM + S3 + policiesCluster + controller bootstrap ONLY

Self-check: If generated code still uses Terraform for IRSA roles or S3 buckets for addons, that is Pattern 2a, NOT 2b.

Pattern 2b does NOT prescribe which controller. The choice is: ACK, Crossplane, or any K8s-native AWS controller. KRO provides orchestration on top (composing multiple resources into RGDs). Always search the internet for latest KRO docs before generating Pattern 2b code.

Workflow

Step 1: Gather Requirements

Accept requirements via interactive questionnaire or a requirements YAML file. If YAML is supplied, validate coverage (cluster, compute, networking, addons, auth, compliance, multi-tenancy) and prompt for gaps.

Step 2: Select Pattern

Based on requirements, select Pattern 1, 2a, or 2b from the decision matrix.

Step 3: Create Project Structure

projects/<project-name>/
├── design/        # Architecture docs (eks-design skill)
└── code/          # Terraform code (this skill)

Step 4: Generate Pattern Scaffold

Generate root Terraform files under projects/<project-name>/code/ following terraform-skill conventions.

  • Pattern 1 -- main.tf implements two-phase module architecture (Critical Rule 1). Phase 1: LBC + Gatekeeper with wait = true. Phase 2: all remaining addons with depends_on = [module.eks_addons_webhooks].
  • Pattern 2a/2b -- main.tf provisions EKS cluster and GitOps Bridge. For 2a include IRSA roles. For 2b include only controller bootstrap IAM.

Before generating, search the internet for latest stable versions of terraform-aws-modules/eks, terraform-aws-modules/vpc, aws-ia/eks-blueprints-addons, and all Helm charts. Pin exact versions. See references/version-matrix.md.

Step 5: Generate Required Modules

Under projects/<project-name>/code/modules/:

  • eks-cluster/ -- always. Wraps terraform-aws-modules/eks with opinionated defaults from references/baseline-defaults.md.
  • custom-addons/ -- if custom addons enabled. See references/addon-catalog.md.
  • kyverno-policies/ -- if Kyverno CIS benchmark enabled.
  • eks-tenants/ -- if multi-tenancy enabled.
  • eks-gitops-bridge/ -- Pattern 2 only.

Step 6-7: Configure and Customize

Edit configs/*.yaml based on requirements and apply customization patches per references/customization-guide.md:

  • Air-gapped, Enterprise proxy, Private registry, Compliance-strict

Step 8: Generate GitOps Artifacts (Pattern 2 only)

Generate the gitops/ tree with ArgoCD ApplicationSets. Use cluster ARN as destination server (Critical Rule 10). For OCI Helm charts, omit oci:// prefix in repoURL (Critical Rule 10b).

Step 9-10: README and Validate

Generate README and run scripts/validate_project.sh to verify structure, formatting, and critical configuration.

Critical Build Rules

Non-negotiable lessons from production deployments. Violating any causes deployment failures. See references/lessons-learned.md for full context.

1. Two-Phase Module Architecture (Pattern 1)

Split eks-blueprints-addons into TWO module calls:

  • Phase 1: LBC + Gatekeeper only, wait: true
  • Phase 2: All other addons, depends_on = [module.eks_addons_webhooks]

LBC and Gatekeeper register webhooks (failurePolicy: Fail) before pods are ready. Without two-phase, these webhooks block all other addon deployments.

2. before_compute: true

MANDATORY for vpc-cni and eks-pod-identity-agent. Without this, nodes fail with NodeCreationFailure: NetworkPluginNotReady.

3. Cluster-Autoscaler Version Match

Image tag MUST match EKS K8s minor version (e.g., v1.x.y for EKS 1.x).

4. LBC Requires Explicit vpcId

IMDS fallback fails with hop-limit restrictions. Always set vpcId in LBC Helm values.

5. Multus DISABLED

Thick-plugin pod-lookup race blocks ALL new pod creation. Never enable.

6. Version Pinning -- Always Search Internet

Never rely on module defaults or hardcoded versions. Search for every addon and module version before generating. See references/version-matrix.md.

7. Kyverno syncOptions (Pattern 2)

Use Replace=true, NOT ServerSideApply=true. SSA conflicts with ArgoCD selfHeal: true + --force.

8. Velero Configuration

Three-part config: S3 bucket (encrypted) + Auth (Pod Identity or IRSA) + Helm values (upgradeCRDs: false, pin kubectl.image.tag).

9. ACK/KRO Are Capabilities, Crossplane Is Not

ACK and KRO run as EKS Capabilities (no pods). Validate via CRDs, not kubectl pods. Crossplane runs as pods via Helm chart.

10. ArgoCD Destination Server (Pattern 2)

Use cluster ARN as destination server, NOT https://kubernetes.default.svc. AppProjects require sourceNamespaces: [argocd].

10b. ArgoCD OCI Helm Chart repoURL

Do NOT include oci:// prefix in repoURL. Use public.ecr.aws/karpenter with chart: karpenter.

10c. S3 Bucket Persistence in Destroy/Apply Cycles (Pattern 2b)

S3 buckets persist after terraform destroy because the controller is deleted first. Add aws s3 rb s3://<bucket> --force || true as pre-destroy step.

11. Use HashiCorp Terraform, NOT OpenTofu

OpenTofu v1.10.6 has severe depends_on performance regression (30+ min plan vs < 2 min with Terraform v1.14.5). Require HashiCorp Terraform v1.14.5+.

12. ArgoCD EKS Capability Requires IAM Identity Center

The AWS-managed ArgoCD EKS Capability requires an existing IAM Identity Center instance. Self-managed ArgoCD can use any auth method.

Customization Rules

ConstraintTriggerGuide
Air-gappednetwork.air_gapped = truecustomization-guide.md S1
Enterprise proxynetwork.proxy.enabled = truecustomization-guide.md S2
Private registryregistry.type = "private"customization-guide.md S3
Compliance-strictSecurity posture requirementcustomization-guide.md S4

Output Structure

Pattern 1

projects/<project-name>/code/
├── main.tf                    # Two-phase module architecture
├── locals.tf, data.tf, providers.tf, variables.tf, outputs.tf, versions.tf
├── modules/
│   ├── eks-cluster/
│   ├── custom-addons/
│   └── kyverno-policies/
├── configs/
│   ├── cluster.yaml, compute.yaml, addons.yaml, backend.hcl
└── validation-checklist.md

Pattern 2

projects/<project-name>/code/
├── main.tf                    # Cluster + GitOps Bridge
├── locals.tf, data.tf, providers.tf, variables.tf, outputs.tf, versions.tf
├── modules/
│   ├── eks-cluster/
│   ├── eks-gitops-bridge/
│   └── custom-addons/
├── configs/
│   ├── cluster.yaml, compute.yaml, addons.yaml, backend.hcl
├── gitops/
│   ├── addons/applicationset.yaml
│   ├── custom-addons/applicationset.yaml
│   ├── bootstrap/argocd-projects.yaml
│   └── tenants/applicationset.yaml
└── validation-checklist.md

Deployment

Pattern 1:

bash
cd projects/<project-name>/code
terraform init -backend-config=configs/backend.hcl
terraform plan && terraform apply

Pattern 2:

bash
cd projects/<project-name>/code
terraform init -backend-config=configs/backend.hcl
terraform plan && terraform apply
aws eks update-kubeconfig --name <CLUSTER_NAME> --region <REGION>
kubectl apply -f gitops/bootstrap/argocd-projects.yaml
kubectl apply -f gitops/addons/applicationset.yaml
kubectl apply -f gitops/custom-addons/applicationset.yaml

Expected Timing (HashiCorp Terraform v1.14.5+)

StepPattern 1Pattern 2
terraform plan< 2 min< 1 min
terraform apply~18 min~16 min
ArgoCD syncN/A~5 min
terraform destroy~10 min~15 min

Completion Checklist

Every item must be done before handoff:

  • Internet search for latest versions (not from cached knowledge)
  • Pattern selected and confirmed
  • Project structure created with pattern scaffold
  • Required modules generated
  • Configuration customized with project-specific values
  • Customization patches applied (if applicable)
  • GitOps artifacts generated (Pattern 2 only)
  • terraform fmt -check passes
  • before_compute: true set for vpc-cni and eks-pod-identity-agent
  • Two-phase module architecture present (Pattern 1)
  • All versions explicitly pinned
  • Multus NOT enabled
  • validation-checklist.md generated

References

Read these as needed based on the task at hand:

  • Baseline Defaults -- Read when generating cluster, compute, networking, or security configuration. Covers all default values applied to every project.
  • Pattern Guide -- Read when selecting between patterns or implementing pattern-specific architecture.
  • Customization Guide -- Read when applying air-gapped, proxy, private registry, or compliance constraints.
  • Addon Catalog -- Read when configuring specific addons or adding custom addons. Covers all 29+ supported addons.
  • Lessons Learned -- Read when troubleshooting deployment failures or understanding why a Critical Build Rule exists.
  • Version Matrix -- Read when looking up authoritative version sources for addons and Terraform modules.
  • Checkov Config -- Read when setting up security scanning for generated Terraform code.

Tệp đi kèm

Khi kỹ năng đã được tải, mô hình có thể đọc các tệp này nếu cần. Các tệp này chỉ dùng để đọc và không bao giờ được thực thi.

Câu hỏi thường gặp

Kỹ năng AI Eks Build làm được gì?

Dùng khi xây dựng cụm EKS. Tạo các dự án Terraform hoàn chỉnh, sẵn sàng cho môi trường production, với tùy chọn tích hợp GitOps của ArgoCD. Xử lý các ràng buộc theo môi trường: mạng cô lập, chỉ dùng VPC endpoint, proxy doanh nghiệp, registry container riêng và yêu cầu tuân thủ. Hỗ trợ 3 mô hình: Terraform toàn phần, ArgoCD+Terraform, ArgoCD+ACK/KRO. Bao gồm các module đã được xác thực, thứ tự webhook hai giai đoạn, IRSA/Pod Identity và hơn 29 cấu hình tiện ích bổ sung. Bạn có thể trả lời câu hỏi tương tác hoặc cung cấp YAML yêu cầu. Cũng dùng khi (1) tạo mã Terraform cho EKS từ đầu, (2) tạo...

Vì sao nên dùng Eks Build trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Eks Build là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Eks Build trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/aws-samples/sample-apex-skills/tree/main/skills/eks-build. TypingMind đọc tệp SKILL.md, đóng gói các tệp đi kèm rồi cài đặt cả gói dưới dạng một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Eks Build?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Eks Build với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Eks Build với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Eks Build có miễn phí không?

Có. Kỹ năng này được aws-samples phát hành trên GitHub theo giấy phép MIT-0. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇