Files
terraform-aws-eks/examples/instance_refresh
2021-10-12 15:20:14 +02:00
..
2021-10-12 15:20:14 +02:00
2021-10-12 15:20:14 +02:00
2021-10-12 15:20:14 +02:00
2021-10-12 15:20:14 +02:00

Instance refresh example

This is EKS example using instance refresh feature for worker groups.

See the official documentation for more details.

Usage

To run this example you need to execute:

$ terraform init
$ terraform plan
$ terraform apply

Note that this example may create resources which cost money. Run terraform destroy when you don't need these resources.

Requirements

Name Version
terraform >= 0.13.1
aws >= 3.22.0
helm ~> 2.0
kubernetes ~> 2.0
local >= 1.4
random >= 2.1

Providers

Name Version
aws >= 3.22.0
helm ~> 2.0
random >= 2.1

Modules

Name Source Version
aws_node_termination_handler_role terraform-aws-modules/iam/aws//modules/iam-assumable-role-with-oidc 4.1.0
aws_node_termination_handler_sqs terraform-aws-modules/sqs/aws ~> 3.0.0
eks ../..
vpc terraform-aws-modules/vpc/aws ~> 3.0

Resources

Name Type
aws_autoscaling_lifecycle_hook.aws_node_termination_handler resource
aws_cloudwatch_event_rule.aws_node_termination_handler_asg resource
aws_cloudwatch_event_rule.aws_node_termination_handler_spot resource
aws_cloudwatch_event_target.aws_node_termination_handler_asg resource
aws_cloudwatch_event_target.aws_node_termination_handler_spot resource
aws_iam_policy.aws_node_termination_handler resource
helm_release.aws_node_termination_handler resource
random_string.suffix resource
aws_availability_zones.available data source
aws_caller_identity.current data source
aws_eks_cluster.cluster data source
aws_eks_cluster_auth.cluster data source
aws_iam_policy_document.aws_node_termination_handler data source
aws_iam_policy_document.aws_node_termination_handler_events data source
aws_region.current data source

Inputs

No inputs.

Outputs

Name Description
cluster_endpoint Endpoint for EKS control plane.
cluster_security_group_id Security group ids attached to the cluster control plane.
config_map_aws_auth A kubernetes configuration to authenticate to this EKS cluster.
kubectl_config kubectl config as generated by the module.
sqs_queue_asg_notification_arn SQS queue ASG notification ARN
sqs_queue_asg_notification_url SQS queue ASG notification URL