-
Notifications
You must be signed in to change notification settings - Fork 0
/
waypoint.hcl
47 lines (41 loc) · 1017 Bytes
/
waypoint.hcl
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
project = "init"
variable "registry_username" {
type = string
}
variable "registry_password" {
type = string
sensitive = true
}
runner {
enabled = true
// profile set to avoid kaniko --force issue
profile = "nomad-bootstrap-profile"
data_source "git" {
url = "https://github.com/dotdiego/waypoint-test.git"
}
}
app "demo" {
// get a small image from docker because we can't bypass the build step
build {
use "docker-pull" {
image = "hello-world"
tag = "latest"
disable_entrypoint = true
}
// push it to docker registry because remote-runner needs a registry block
registry {
use "docker" {
image = "${var.registry_username}/hello-world"
tag = "latest"
username = var.registry_username
password = var.registry_password
}
}
}
// finally deploy to nomad
deploy {
use "nomad-jobspec" {
jobspec = templatefile("${path.project}/webapp.nomad")
}
}
}