Cloud/Terraform

Terraform - Target Group 추가 (1. instance / 2. IP Address

잇(IT) 2022. 7. 7. 23:01

- 타겟 그룹 먼저 생성

resource "aws_lb_target_group" "test" {
  name     = "tf-example-lb-tg"
  port     = 80
  protocol = "HTTP"
  vpc_id   = aws_vpc.main.id
}

resource "aws_vpc" "main" {
  cidr_block = "10.0.0.0/16"
}

 

- health check

 

 

 

 

728x90