homelab-nomad/services/service/main.tf

32 lines
852 B
Terraform
Raw Normal View History

resource "nomad_job" "service" {
jobspec = templatefile("${path.module}/service_template.nomad", {
name = var.name
image = var.image
args = var.args
env = var.env
service_port = var.service_port
2022-11-15 19:43:05 +00:00
ports = var.ports
sticky_disk = var.sticky_disk
resources = var.resources
2022-11-15 19:43:05 +00:00
service_tags = var.service_tags
ingress = var.ingress
ingress_rule = var.ingress_rule
ingress_middlewares = var.ingress_middlewares
healthcheck_path = var.healthcheck_path
metrics_port_name = var.metrics_port_name
templates = var.templates
host_volumes = var.host_volumes
upstreams = var.upstreams
use_mysql = var.use_mysql
use_redis = var.use_redis
use_ldap = var.use_ldap
use_vault = var.use_vault
mysql_bootstrap = var.mysql_bootstrap
})
}