diff --git a/cluster/staging/app/garage/config/garage.toml b/cluster/staging/app/garage/config/garage.toml index 3686338..f14a602 100644 --- a/cluster/staging/app/garage/config/garage.toml +++ b/cluster/staging/app/garage/config/garage.toml @@ -10,9 +10,6 @@ rpc_bind_addr = "[{{ env "meta.public_ipv6" }}]:3991" rpc_public_addr = "[{{ env "meta.public_ipv6" }}]:3991" rpc_secret = "{{ key "secrets/garage-staging/rpc_secret" | trimSpace }}" -#consul_host = "localhost:8500" -#consul_service_name = "garage-staging-rpc-self-advertised" - bootstrap_peers = [] [consul_discovery] diff --git a/cluster/staging/app/garage/deploy/garage-nix2.hcl b/cluster/staging/app/garage/deploy/garage-nix2.hcl index a60b506..5baf797 100644 --- a/cluster/staging/app/garage/deploy/garage-nix2.hcl +++ b/cluster/staging/app/garage/deploy/garage-nix2.hcl @@ -1,13 +1,13 @@ job "garage-staging" { type = "system" - #datacenters = [ "neptune", "pluton" ] + priority = 90 + datacenters = [ "neptune" ] - priority = 80 - - constraint { - attribute = "${attr.cpu.arch}" - value = "amd64" + update { + max_parallel = 1 + stagger = "30s" + min_healthy_time = "10s" } group "garage-staging" { @@ -19,43 +19,6 @@ job "garage-staging" { port "admin" { static = 3909 } } - update { - max_parallel = 1 - min_healthy_time = "30s" - healthy_deadline = "5m" - } - - # task "repair" { - # lifecycle { - # hook = "prestart" - # sidecar = false - # } - - # driver = "docker" - - # config { - # image = "dxflrs/amd64_garage:v0.7.99-k2v" - # command = "/garage" - # args = [ "offline-repair", "--yes", "object_counters" ] - # network_mode = "host" - # volumes = [ - # "/mnt/storage/garage-staging/data:/data", - # "/mnt/ssd/garage-staging/meta:/meta", - # "secrets/garage.toml:/etc/garage.toml", - # ] - # } - - # template { - # data = file("../config/garage.toml") - # destination = "secrets/garage.toml" - # } - - # resources { - # memory = 2000 - # cpu = 1000 - # } - # } - task "server" { driver = "nix2" @@ -71,6 +34,12 @@ job "garage-staging" { "/mnt/ssd/garage-staging/meta" = "/meta", } } + + env = { + RUST_LOG = "garage=debug", + } + + # files currently owned by root, we don't want to chown everything user = "root" template { @@ -93,14 +62,6 @@ job "garage-staging" { destination = "etc/garage/consul-client.key" } - template { - data = <