aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/digitalocean/server/variables.tf
blob: 6ce251614fdbbdb3006aca84a797d30401fd8c7b (plain) (blame)
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
variable "region" {
  type = string

  # Get the full list, along with available droplet sizes:
  #     curl -H "Content-Type: application/json" -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" "https://api.digitalocean.com/v2/regions" | jq .
}
variable "project_id" {
  type = string
}

variable "name" {
  type = string
}
variable "vpc_id" {
  type = string
}
variable "volume_ids" {
  type    = list(string)
  default = []
}

variable "user" {
  type = string
}
variable "ssh_keys" {
  type = list(string)
}
variable "ssh_port" {
  type    = string
  default = "22"
}

variable "image" {
  type = string

  #default = "debian-12-x64"
  #default = "debian-13-x64"
  #default = "ubuntu-22-04-x64"
  default = "ubuntu-24-04-x64"

  # Get the full list:
  #     curl -H "Content-Type: application/json" -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" "https://api.digitalocean.com/v2/images?type=distribution" | jq .
}
variable "size" {
  type = string

  default = "s-1vcpu-2gb"

  # Get the full list:
  #     curl -H "Content-Type: application/json" -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" "https://api.digitalocean.com/v2/sizes" | jq .
}

variable "alert_cpu_enable" {
  type    = bool
  default = true
}
variable "alert_cpu_threshold" {
  type    = number
  default = 80
}
variable "alert_loadavg1_enable" {
  type    = bool
  default = true
}
variable "alert_loadavg1_threshold" {
  type    = number
  default = 5
}