From e73eab3d41a34e71845647422a1bd6f03d3d37e6 Mon Sep 17 00:00:00 2001 From: Benjamin Toby Date: Tue, 20 Oct 2026 07:45:06 +0100 Subject: [PATCH] Require the current container init setting on update --- README.md | 2 ++ install.sh | 1 + 2 files changed, 3 insertions(+) diff --git a/README.md b/README.md index 8651275..972ff17 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Cobble +[![CI](https://github.com/Moduletrace/cobble/actions/workflows/ci.yml/badge.svg)](https://github.com/Moduletrace/cobble/actions/workflows/ci.yml) + A self-hosted crew of small AI worker bots. Cobble gives you a coordinator bot and a crew of workers, each with its own diff --git a/install.sh b/install.sh index 808b3aa..f47ac21 100644 --- a/install.sh +++ b/install.sh @@ -379,6 +379,7 @@ container_matches() { [ "$(docker_socket_mounted)" = "$DOCKER_SOCKET" ] || return 1 [ "$(docker inspect -f '{{with index .HostConfig.PortBindings "'"$PORT"'/tcp"}}{{range .}}{{.HostIp}}:{{.HostPort}}{{end}}{{end}}' "$CONTAINER")" = "$BIND:$PORT" ] || return 1 [ "$(docker inspect -f '{{.HostConfig.RestartPolicy.Name}}' "$CONTAINER")" = "unless-stopped" ] || return 1 + [ "$(docker inspect -f '{{.HostConfig.Init}}' "$CONTAINER")" = "true" ] || return 1 docker inspect -f '{{range .Config.Env}}{{println .}}{{end}}' "$CONTAINER" | grep -qx "MAIN_SERVER=1" || return 1 docker inspect -f '{{range .Config.Env}}{{println .}}{{end}}' "$CONTAINER" | grep -qx "PORT=$PORT" || return 1 docker inspect -f '{{range $name, $net := .NetworkSettings.Networks}}{{println $name}}{{end}}' "$CONTAINER" | grep -qx "$NETWORK" || return 1