Repository: basecamp/kamal (Ruby)

Issue:
[2.4.0] First time `kamal setup` fails when an accessory has `proxy:` section
Setting up kamal with `kamal setup` on a brand new Ubuntu VM (hetzner), fails with `No such container: kamal-proxy`

It looks like `setup` command is not running `kamal:cli:proxy:boot` before booting accessories. should that now be executed unconditionally or only when an accessory has the `proxy:` section?

Feature introduced in 2.4.0 in https://github.com/basecamp/kamal/pull/981

My proposed fix here: https://github.com/basecamp/kamal/pull/1308

Output:
```
kamal setup
  INFO [545724da] Running /usr/bin/env mkdir -p .kamal on 123.123.123.123
  INFO [545724da] Finished in 1.561 seconds with exit status 0 (successful).
Acquiring the deploy lock...
Ensure Docker is installed...
  INFO [db7c098e] Running docker -v on 123.123.123.123
  INFO [db7c098e] Finished in 0.152 seconds with exit status 127 (failed).
  INFO [41c3f18c] Running [ "${EUID:-$(id -u)}" -eq 0 ] || command -v sudo >/dev/null || command -v su >/dev/null on 123.123.123.123
  INFO [41c3f18c] Finished in 0.160 seconds with exit status 0 (successful).
  INFO Missing Docker on 123.123.123.123. Installing…
  INFO [21366e3f] Running /usr/bin/env sh -c 'curl -fsSL https://get.docker.com || wget -O - https://get.docker.com || echo "exit 1"' | sh on 123.123.123.123
  INFO [21366e3f] Finished in 17.154 seconds with exit status 0 (successful).
  INFO [1681b27a] Running docker login ghcr.io -u [REDACTED] -p [REDACTED] on 123.123.123.123
  INFO [1681b27a] Finished in 0.616 seconds with exit status 0 (successful).
  INFO [2ec90e33] Running docker network create kamal on 123.123.123.123
  INFO [2ec90e33] Finished in 0.270 seconds with exit status 0 (successful).
  INFO [879d2dc0] Running /usr/bin/env mkdir -p .kamal/apps/example/env/accessories on 123.123.123.123
  INFO [879d2dc0] Finished in 0.158 seconds with exit status 0 (successful).
  INFO Uploading .kamal/apps/example/env/accessories/imgproxy.env 100.0%
  INFO [238cf393] Running docker run --name example-imgproxy --detach --restart unless-stopped --network kamal --log-opt max-size="10m" --env IMGPROXY_KEY="deadbeef" --env IMGPROXY_SALT="deadbeef" --env-file .kamal/apps/example/env/accessories/imgproxy.env --label service="example-imgproxy" ghcr.io/imgproxy/imgproxy:latest on 123.123.123.123
  INFO [238cf393] Finished in 4.197 seconds with exit status 0 (successful).
  INFO [5cf3b40e] Running docker container ls --filter name=^example-imgproxy$ --quiet on 123.123.123.123
  INFO [5cf3b40e] Finished in 0.176 seconds with exit status 0 (successful).
  INFO [6313e983] Running docker exec kamal-proxy kamal-proxy deploy example-imgproxy --target="13eb22bac12f:8080" --host="images.my-domain.com" --deploy-timeout="30s" --drain-timeout="30s" --health-check-path="/health" --buffer-requests --buffer-responses --log-request-header="Cache-Control" --log-request-header="Last-Modified" --log-request-header="User-Agent" on 123.123.123.123
Releasing the deploy lock...
  Finished all in 31.7 seconds
  ERROR (SSHKit::Command::Failed): Exception while executing on host 123.123.123.123: docker exit status: 1
docker stdout: Nothing written
docker stderr: Error response from daemon: No such container: kamal-proxy
```



deploy.yml

```yaml
service: example

image: my-org/repo
registry:
  server: ghcr.io
  username:
    - KAMAL_REGISTRY_USER
  password:
    - KAMAL_REGISTRY_PASSWORD
builder:
  arch: arm64

servers:
  web:
    - 123.123.123.123
proxy:
  ssl: false
  host: my-domain.com
  app_port: 3000

env:
  secret:
    - RAILS_MASTER_KEY
    - DATABASE_URL

accessories:
  imgproxy:
    image: ghcr.io/imgproxy/imgproxy:latest
    host: 123.123.123.123
    proxy:
      ssl: false
      host: images.my-domain.com
      app_port: 8080
      healthcheck:
        path: /health
    env:
      clear:
        IMGPROXY_KEY: "deadbeef"
        IMGPROXY_SALT: "deadbeef"
```



Fix (patch):
diff --git a/lib/kamal/cli/main.rb b/lib/kamal/cli/main.rb
index 5fdb5469a..b06a34477 100644
--- a/lib/kamal/cli/main.rb
+++ b/lib/kamal/cli/main.rb
@@ -9,6 +9,9 @@ def setup
         say "Ensure Docker is installed...", :magenta
         invoke "kamal:cli:server:bootstrap", [], invoke_options
 
+        say "Ensure kamal-proxy is running...", :magenta
+        invoke "kamal:cli:proxy:boot", [], invoke_options
+
         invoke "kamal:cli:accessory:boot", [ "all" ], invoke_options
         deploy
       end