Terraform으로 AWS 클라우드 계정 관리하기
Terraform에서 AWS 클라우드 계정을 코드로 관리하기
개요
Terraform에서 AWS Cloud Account를 정의하는 방법
사전 요구 사항
1단계: 변수 정의
variable "panther_api_token" {
description = "Panther API 토큰"
type = string
sensitive = true
}
variable "panther_api_url" {
description = "Panther API URL"
type = string
}
variable "integration_label" {
description = "AWS Cloud Account 통합의 표시 이름."
type = string
}
variable "aws_account_id" {
description = "12자리 AWS 계정 ID."
type = string
}
variable "audit_role" {
description = "Panther가 AWS 계정을 스캔할 때 사용하는 IAM 역할 ARN."
type = string
}
// (선택 사항) 스캔에서 제외할 리전, 리소스 유형 및 ARN 정규식 패턴.
variable "region_ignore_list" {
description = "스캔에서 제외할 AWS 리전."
type = list(string)
default = []
}
variable "resource_type_ignore_list" {
description = "스캔에서 제외할 리소스 유형(예: AWS.S3.Bucket)."
type = list(string)
default = []
}
variable "resource_regex_ignore_list" {
description = "스캔에서 제외할 리소스 ARN과 일치하는 정규식 패턴."
type = list(string)
default = []
}2단계: 정의된 변수에 값을 제공하세요
3단계: Terraform 제공자 정의
4단계: Panther AWS Cloud Account 리소스 정의
리소스 참조
panther_aws_cloud_account
panther_aws_cloud_account인수
이름
유형
필수
설명
aws_scan_config
aws_scan_config이름
유형
필수
설명
속성
이름
유형
설명
기존 AWS Cloud Account 가져오기
마지막 업데이트
도움이 되었나요?

