Wanderer is a deployment manager for HashiCorp Nomad for automated deployments of new job versions via CI/CD pipelines.
- Provides a centralized repository for Nomad HCL templates
- Offers API for CD tools to automate deployment of new versions
- Simple Web UI for editing templates & monitoring deployments
- Supports Nomad instances behind Cloudflare Access Zero Trust network
- GitHub Actions Workflow available for easy pipeline integration
See Development Project for more details.
Built with Go, Tailwind CSS and SQLite. Contains 0 lines of JavaScript 👀
As shown in the diagram above, Wanderer acts as a deployment manager between your CI/CD pipeline and your Nomad cluster.
The build pipeline will instruct Wanderer to deploy a new version of a job, after which the predefined job template will be injected with the currently tagged version.
Wanderer also supports multiple versions in one template, for example a web project with an API backend BACKEND_VERSION
and a frontend FRONTEND_VERSION
.
The predefined Nomad HCL templates need to contain version selectors in the following syntax: {{ VERSION_NAME }}
The following job defined a BACKEND_VERSION
which will be replaced by the actual version during deployment by Wanderer.
job "my-service" {
type = "service"
group "backend" {
task "app" {
driver = "docker"
config {
image = "my-service:{{ BACKEND_VERSION }}"
}
}
}
}
You can also define the version selectors in the meta
block for more structure.
job "my-service" {
type = "service"
meta {
version_backend = "{{ BACKEND_VERSION }}"
version_frontend = "{{ FRONTEND_VERSION }}"
}
group "backend" {
task "app" {
driver = "docker"
config {
image = "my-service/backend:{{ env "NOMAD_META_version_backend" }}"
}
}
}
group "frontend" {
task "app" {
driver = "docker"
config {
image = "my-service/frontend:{{ env "NOMAD_META_version_frontend" }}"
}
}
}
}
docker pull ghcr.io/romanzipp/wanderer:latest
See repository for more information.
docker build -t wanderer:latest .
docker run \
-v "$(pwd)/data/:/app/data/" \
-v "$(pwd)/.env:/app/.env" \
-p 8080:8080 \
wanderer:latest
You can also just deploy Wanderer via Nomad itself.
job "wanderer" {
type = "service"
group "wanderer" {
network {
mode = "bridge"
port "http" {
to = 8080
}
}
service {
name = "wanderer"
port = "http"
}
task "wanderer" {
driver = "docker"
config {
image = "ghcr.io/romanzipp/wanderer:latest"
ports = ["http"]
volumes = [
"local/.env:/app/.env"
]
mount {
type = "bind"
target = "/app/data/"
source = "/opt/wanderer/data/"
readonly = false
bind_options {
propagation = "rshared"
}
}
}
template {
destination = "local/.env"
change_mode = "restart"
data = <<-EOH
APP_PASSWORD=supersecret
SESSION_LIFETIME=43200
EOH
}
}
}
}
Header: Authorization: <token>
- Go 1.19+
- Yarn
- Docker
go get
gow -e=go,html run .
npm install
npm run watch
Released under the MIT License.