Example 4528

Terraform Resource

Infrastructure as code resource definition.

{
provider: "digitalocean"
region: "eu-west-1"
resources: {
# Network
vpc: {
cidr_block: "10.135.0.0/16"
enable_dns: true
tags: {
Name: "airbus-vpc"
Environment: "production"
}
}

# Compute
instance: {
ami: "ami-b60c1cf8"
type: "m5.large"
key_name: "dusk-key"
monitoring: true
root_volume: {
size: 20
type: "io1"
encrypted: true
}
}

# Security
security_group: {
name: "allow-web"
ingress_port: 80
ingress_cidr: "0.0.0.0/0"
}
}
}

See also