-
Notifications
You must be signed in to change notification settings - Fork 0
/
compute.tf
26 lines (25 loc) · 754 Bytes
/
compute.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
resource "linode_instance" "vpn" {
label = join(".", [random_pet.hostname.id, "vpn"])
image = "linode/debian10"
region = var.region
type = "g6-nanode-1"
authorized_keys = [chomp(tls_private_key.vpn.public_key_openssh)]
tags = ["osint", "vpn"]
group = "osint"
swap_size = 1024
private_ip = false
stackscript_id = data.linode_stackscript.hwdsl2.id
stackscript_data = {
VPN_USER = var.vpn_username,
VPN_PASSWORD = random_password.password.result,
VPN_IPSEC_PSK = random_password.psk.result
}
alerts {
cpu = 80
transfer_quota = 90
}
}
resource "tls_private_key" "vpn" {
algorithm = "ECDSA"
ecdsa_curve = "P384"
}