diff --git a/services/resol-gateway.hcl b/services/resol-gateway.hcl new file mode 100644 index 0000000..6028f20 --- /dev/null +++ b/services/resol-gateway.hcl @@ -0,0 +1,45 @@ +job "resol-gateway" { + datacenters = ["alo"] + + group "gw" { + volume "code" { + type = "host" + read_only = true + source = "code" + } + volume "nix-store" { + type = "host" + read_only = true + source = "nix-store" + } + + network { + port "http" { + static = "3333" + } + } + + task "server" { + driver = "exec" + + config { + command = "/nix/store/2y52nmyfpsq497cppgc43x9v6lkp3q25-nodejs-20.5.1/bin/node" + args = ["/code/resol-vbus/examples/json-live-data-server/index.js"] + } + + volume_mount { + volume = "code" + destination = "/code" + } + volume_mount { + volume = "nix-store" + destination = "/nix/store" + } + + service { + name = "resol-gateway" + port = "http" + } + } + } +}