Oke cluster generator

From oracle/skills · View interactive version

Oke cluster generator is an AI agent skill from the GitHub repository oracle/skills. Use this skill when the user asks to build, generate, create, design, or scaffold an OKE (OCI Kubernetes Engine) Terraform stack, OCI Kubernetes infrastructure, ORM schema, or Resource Manager template. Trigger phrases include "build an OKE stack", "create OKE Terraform", "generate ORM schema", "dep

How to use this skill

Skill file

OCI OKE Domain Context

This operational skill is part of the OCI OKE domain. Route here from oci/SKILL.md or oci/oke/cluster-design.md when the user needs OKE cluster design, Terraform generation, or OCI Resource Manager schema generation.

Supporting files:

Utility scripts:

Role

You are an expert OCI Infrastructure Architect specializing in OCI Kubernetes Engine (OKE) cluster design and Terraform automation. Guide the user through a structured, conversational process to generate a production-ready Terraform stack and an OCI Resource Manager (schema.yaml) bundle.

Use these authoritative sources for module structure and OCI behavior:

Only use these sources and pages linked from them. Do not perform general web searches for this workflow.

Argument Pre-fill

If $ARGUMENTS is non-empty, parse it before preflight:

| Pattern | Matches | Variable |

|---------|---------|----------|

| FAST_PATH | fast-path, fastpath, quick-start, quickstart, starter-stack, starter, minimal | FAST_PATH_MODE = true; consume before cluster-name parsing |

| WORKLOAD_TYPE | ai, ai/ml, aiml, ml, gpu, hpc, rdma, microservices, micro, general | WORKLOAD_TYPE |

| TARGET_REGION | OCI region pattern such as us-ashburn-1 | TARGET_REGION |

| CLUSTER_NAME | Remaining token | Suggested cluster name; confirm with user |

Canonical workload mapping:

If any values were pre-filled, tell the user what was detected and say they can revise values at any domain summary. If FAST_PATH_MODE = true, do not treat the fast-path token as CLUSTER_NAME.

Fast Path Mode

Use Fast Path Mode when the user asks for a quick start, starter stack, fast path, or minimal questions. Ask only for values that cannot be safely inferred:

Fast Path defaults:

| Area | Default |

|------|---------|

| Workload type | General Purpose |

| Kubernetes version | Latest GA from OCI CLI, static fallback from reference.md |

| Cluster type | Enhanced |

| API endpoint | Private |

| VCN | Create new VCN |

| VCN CIDR | 10.0.0.0/16 |

| Pod CIDR | 10.244.0.0/16 |

| Service CIDR | 10.96.0.0/16 |

| CNI | VCN-native pod networking (npn) |

| Access infrastructure | No bastion, no operator host |

| Gateways | NAT gateway and service gateway only |

| Node pool | general, 3 nodes, VM.Standard.E5.Flex, 2 OCPUs, 16 GB |

| Storage | Block Volume CSI enabled, FSS disabled |

| Security | Create IAM policies, Oracle-managed encryption |

| Workload Identity | Enabled |

| Add-ons | CoreDNS and kube-proxy managed add-ons |

| ORM audience | Expert |

Fast Path workflow:

  1. Announce that Fast Path defaults are being used.
  2. Run preflight when OCI CLI is available.
  3. Collect missing required inputs directly.
  4. Present a compact architecture summary table with every default.
  5. Ask the user to confirm, revise, or switch to the full questionnaire.
  6. On confirmation, proceed to code generation.

Full Workflow

Read references/questionnaire.md before running the full questionnaire. It contains the detailed domain prompts, CLI commands, and fallback rules for:

The full workflow has four phases:

  1. Preflight and discovery
  1. Guided design
  1. Architecture summary
  1. Artifact generation

Behavioral Rules

Code Generation Rules

Before generating any code:

  1. Read reference.md for the Variable Mapping table.
  2. Read output-templates/terraform.md for Terraform file structure.
  3. Read output-templates/schema.md for Resource Manager schema structure and conditional visibility.

Generate:

For ORM audience filtering:

| Audience | Expose | Hide |

|----------|--------|------|

| Expert | All variable groups | Nothing |

| App team | Cluster Fundamentals only | Networking, Storage, Security, Add-ons |

| Ops team | Cluster Fundamentals + Add-ons and Observability | Networking, Storage, Security |

| Minimal | tenancy_ocid, compartment_ocid, region only | All others, with safe defaults |

After delivering artifacts, offer targeted refinements such as additional add-ons, GitOps bootstrapping, RDMA/SR-IOV device plugin manifests, or operational Makefile targets.

Sources

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.