-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Example that can terraform plan for sample output.
- Loading branch information
Showing
3 changed files
with
88 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| module "eks-configuration" { | ||
| source = "git@github.it.census.gov:SOA/tfmod-eks-storage-classes.git//" | ||
| #source = "git@github.it.census.gov:SOA/tfmod-eks-configuration.git//?ref=v1.0.0" | ||
|
|
||
| region = var.region | ||
| profile = var.profile | ||
| vpc_id = var.vpc_id | ||
|
|
||
| cluster_name = var.cluster_name | ||
| subnets = var.subnets | ||
| security_group_all_worker_mgmt_id = var.security_group_all_worker_mgmt_id | ||
|
|
||
| oidc_provider_arn = var.oidc_provider_arn | ||
| eks_managed_node_groups_autoscaling_group_names = var.eks_managed_node_groups_autoscaling_group_names | ||
| } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| terraform { | ||
| required_version = ">= 1.5.0" | ||
| } | ||
|
|
||
| provider "aws" { | ||
| profile = var.profile | ||
| region = var.region | ||
| } | ||
|
|
||
| data "aws_eks_cluster" "cluster" { | ||
| name = var.cluster_name | ||
| } | ||
|
|
||
| data "aws_eks_cluster_auth" "cluster" { | ||
| name = var.cluster_name | ||
| } | ||
|
|
||
| provider "kubernetes" { | ||
| host = data.aws_eks_cluster.cluster.endpoint | ||
|
|
||
| cluster_ca_certificate = base64decode(data.aws_eks_cluster.cluster.certificate_authority[0].data) | ||
| token = data.aws_eks_cluster_auth.cluster.token | ||
| } | ||
|
|
||
| provider "helm" { | ||
| kubernetes { | ||
| host = data.aws_eks_cluster.cluster.endpoint | ||
|
|
||
| cluster_ca_certificate = base64decode(data.aws_eks_cluster.cluster.certificate_authority[0].data) | ||
| token = data.aws_eks_cluster_auth.cluster.token | ||
| } | ||
| } | ||
|
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| variable "cluster_name" { | ||
| description = "EKS cluster name name component used through out the EKS cluster describing its purpose (ex: dice-dev)" | ||
| type = string | ||
| } | ||
|
|
||
| variable "region" { | ||
| description = "AWS region" | ||
| type = string | ||
| } | ||
|
|
||
| variable "profile" { | ||
| description = "AWS config profile" | ||
| type = string | ||
| } | ||
|
|
||
| variable "vpc_id" { | ||
| description = "Specify the VPC id that is used by this cluster" | ||
| type = string | ||
| } | ||
|
|
||
| variable "subnets" { | ||
| description = "Specify the subnets used by this cluster" | ||
| type = list(string) | ||
| } | ||
|
|
||
| variable "security_group_all_worker_mgmt_id" { | ||
| description = "The security group representing all of the worker nodes in the cluster." | ||
| type = string | ||
| } | ||
|
|
||
| variable "eks_managed_node_groups_autoscaling_group_names" { | ||
| description = "List of the autoscaling group names created by EKS managed node groups" | ||
| type = list(string) | ||
| } | ||
|
|
||
| variable "oidc_provider_arn" { | ||
| description = "The ARN of the OIDC Provider if `enable_irsa = true`" | ||
| type = string | ||
| } | ||
|
|