[root@s22222 scenario01]# cd 3 [root@s22222 3]# clear [root@s22222 3]# ls *.tf main.tf variables.tf versions.tf [root@s22222 3]# more *.tf :::::::::::::: main.tf :::::::::::::: # VPC > User scenario > Scenario 1. Single Public Subnet # https://docs.ncloud.com/ko/networking/vpc/vpc_userscenario1.html provider "ncloud" { support_vpc = true region = "KR" access_key = var.access_key secret_key = var.secret_key } resource "ncloud_login_key" "key_scn_01" { key_name = var.name_vpc } resource "ncloud_vpc" "vpc_vpc" { name = var.name_vpc ipv4_cidr_block = "10.0.0.0/21" } resource "ncloud_subnet" "subnet_pub1" { name = var.name_pub1 vpc_no = ncloud_vpc.vpc_vpc.id subnet = cidrsubnet(ncloud_vpc.vpc_vpc.ipv4_cidr_block,3 , 2) zone = "KR-1" network_acl_no = ncloud_vpc.vpc_vpc.default_network_acl_no subnet_type = "PUBLIC" // PUBLIC(Public) | PRIVATE(Private) } :::::::::::::: variables.tf :::::::::::::: variable name_vpc { default = "agame-dev-vpc" } variable name_pub1 { default = "agame-dev-pub1" } variable client_ip { default = "3.3.3.3" } variable access_key { default = "ncp_iam_BPAMKR5XsAr52VzPluqr" } variable secret_key { default = "ncp_iam_BPKMKR1DwyNq8NImKqZpe759MRZ3F6aeKD" } :::::::::::::: versions.tf :::::::::::::: terraform { required_providers { ncloud = { source = "navercloudplatform/ncloud" } } required_version = ">= 0.13" } [root@s22222 3]#