The Terraform NIFCLOUD provider is a plugin for Terraform that allows for lifecycle management of NIFCLOUD resources.
terraform {
required_providers {
nifcloud = {
source = "nifcloud/nifcloud"
version = ">= 1.0.0"
}
}
}
provider "nifcloud" {
region = "jp-east-1"
}
resource "nifcloud_key_pair" "deployer" {
key_name = "deployerkey"
public_key = "Base64-encoded public key string"
}
resource "nifcloud_instance" "web" {
image_id = "221"
key_name = nifcloud_key_pair.deployer.key_name
network_interface {
network_id = "net-COMMON_PRIVATE"
}
}
Have a look at the reference docs for more information on the supported resources and data sources.
- Terraform 0.13+