-
Notifications
You must be signed in to change notification settings - Fork 6
/
example-cloudapi.nomad
85 lines (67 loc) · 1.42 KB
/
example-cloudapi.nomad
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
job "bhyve" {
datacenters = ["dc1"]
type = "service"
update {
canary = 1
max_parallel = 1
}
group "example" {
count = 2
task "task" {
driver = "triton"
service {
name = "bhyve-demo-ssh"
tags = ["example"]
port = "22"
address_mode = "driver"
check {
type = "tcp"
port = "22"
interval = "10s"
timeout = "2s"
address_mode = "driver"
check_restart {
limit = 3
grace = "90s"
ignore_warnings = false
}
}
}
config {
package {
name = "sample-2G"
}
api_type = "cloud_api"
cloud_api {
#image = "50719951-4dab-4fc0-9549-b36466614324"
image {
name = "ubuntu-certified-18.04"
version = "20180808"
#most_recent = true
}
networks = [
{
name = "sdc_nat"
},
]
}
fwenabled = true
cns = [
"bhyve_example",
]
tags = {
fwtag = "true"
}
fwrules = {
fwrule0 = "FROM any TO tag fwtag ALLOW tcp PORT 22"
}
}
env {
my_key = "test"
}
meta {
my-key = "my-value"
}
}
}
}