# EKS Cluster

### Creating a standard cluster with minimal parameters

```
resources:
  # EKS Cluster (non-auto mode)
  - type: aws_eks_cluster
    name: eks-cluster1
    props:
      version: "1.31"
      role_arn: "arn:aws:iam::123456789012:role/eks-cluster-role"
      resources_vpc_config:
        subnet_ids:
          - "subnet-0123456789abcdef0"
          - "subnet-0123456789abcdef1"
        endpoint_public_access: true
        endpoint_private_access: true
        security_group_ids:
          - "sg-0123456789abcdef0"
    resources:
      # Managed Node Group - nested under the cluster
      - type: aws_eks_nodegroup
        name: eks-nodegroup1
        props:
          node_role: "arn:aws:iam::123456789012:role/eks-node-role"
          subnets:
            - "subnet-0123456789abcdef0"
            - "subnet-0123456789abcdef1"
          scaling_config:
            min_size: 1
            desired_size: 2
            max_size: 3
          instance_types:
            - "t3.medium"
            - "t3.large"
          capacity_type: "ON_DEMAND"
```

#### Example price for above configuration

```
eks-cluster1 (action: create)
=> Price (Control plane standard support - price: $0.10/Hrs, monthly: $74.40)
-- eks-nodegroup1 (action: create, instance-size: t3.large, price: $0.0832/Hrs, monthly: $61.90, node-count: 3, monthly-nodes: $185.70)
```

### Creating an auto mode cluster with minimal parameters

```
resources:
  # EKS Cluster (auto mode)
  - type: aws_eks_cluster
    name: eks-cluster2
    props:
      version: "1.31"
      role_arn: "arn:aws:iam::123456789012:role/eks-cluster-role"
      compute_config:
        enabled: true
      resources_vpc_config:
        subnet_ids:
          - "subnet-0123456789abcdef0"
          - "subnet-0123456789abcdef1"
        endpoint_public_access: true
        endpoint_private_access: true
```

#### Example price for above configuration

```
eks-cluster2 (action: create)
=> Price (Control plane standard support - price: $0.10/Hrs, monthly: $74.40)
=> Price (Additional per node (t3.medium) - price: $0.00499/Hrs, monthly: $3.71)
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.mechcloud.io/cloud-computing/stateless-iac/aws/examples-resources-with-cost/eks/eks-cluster.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
