mirror of
https://github.com/ysoftdevs/terraform-aws-eks.git
synced 2026-03-24 02:11:04 +01:00
Add ability to pass computed values to cluster_security_group_id and worker_security_group_id (#186)
* Add ability to pass computer values to cluster_security_group_id and worker_security_group_id * Fix contributer name in CHANGELOG.md * Format variables.tf file
This commit is contained in:
committed by
Max Williams
parent
1822a677dc
commit
9d6740e116
@@ -24,7 +24,7 @@ resource "aws_security_group" "cluster" {
|
||||
description = "EKS cluster security group."
|
||||
vpc_id = "${var.vpc_id}"
|
||||
tags = "${merge(var.tags, map("Name", "${var.cluster_name}-eks_cluster_sg"))}"
|
||||
count = "${var.cluster_security_group_id == "" ? 1 : 0}"
|
||||
count = "${var.cluster_create_security_group ? 1 : 0}"
|
||||
}
|
||||
|
||||
resource "aws_security_group_rule" "cluster_egress_internet" {
|
||||
@@ -35,7 +35,7 @@ resource "aws_security_group_rule" "cluster_egress_internet" {
|
||||
from_port = 0
|
||||
to_port = 0
|
||||
type = "egress"
|
||||
count = "${var.cluster_security_group_id == "" ? 1 : 0}"
|
||||
count = "${var.cluster_create_security_group ? 1 : 0}"
|
||||
}
|
||||
|
||||
resource "aws_security_group_rule" "cluster_https_worker_ingress" {
|
||||
@@ -46,7 +46,7 @@ resource "aws_security_group_rule" "cluster_https_worker_ingress" {
|
||||
from_port = 443
|
||||
to_port = 443
|
||||
type = "ingress"
|
||||
count = "${var.cluster_security_group_id == "" ? 1 : 0}"
|
||||
count = "${var.cluster_create_security_group ? 1 : 0}"
|
||||
}
|
||||
|
||||
resource "aws_iam_role" "cluster" {
|
||||
|
||||
Reference in New Issue
Block a user