Add start.sh and Makefile build-only targets

start.sh builds via 'make build' (platform auto-detected) then starts
services detached with 'docker compose up -d'.

Makefile gains build/build-<platform> targets that build images without
starting, mirroring the existing up/<platform> targets.
This commit is contained in:
Claude 2026-03-20 10:06:24 +00:00
parent 00da63ec80
commit b060ec68af
No known key found for this signature in database
2 changed files with 27 additions and 1 deletions

View file

@ -10,10 +10,29 @@
# up-armv6 — linux/arm/v6 (Pi Zero, Pi 1)
COMPOSE = docker compose
BUILD = $(COMPOSE) build
UP = $(COMPOSE) up --build
.PHONY: up up-amd64 up-x64 up-win up-arm64 up-armv7 up-armv6 down logs
.PHONY: build build-amd64 build-x64 build-win build-arm64 build-armv7 build-armv6 \
up up-amd64 up-x64 up-win up-arm64 up-armv7 up-armv6 down logs
# ── Build only (no start) ─────────────────────────────────────────────────────
build:
$(BUILD)
build-amd64 build-x64 build-win:
DOCKER_DEFAULT_PLATFORM=linux/amd64 $(BUILD)
build-arm64:
DOCKER_DEFAULT_PLATFORM=linux/arm64 $(BUILD)
build-armv7:
DOCKER_DEFAULT_PLATFORM=linux/arm/v7 $(BUILD)
build-armv6:
DOCKER_DEFAULT_PLATFORM=linux/arm/v6 $(BUILD)
# ── Build + start (foreground) ────────────────────────────────────────────────
up:
$(UP)

7
infra/start.sh Executable file
View file

@ -0,0 +1,7 @@
#!/usr/bin/env bash
set -euo pipefail
cd "$(dirname "$0")"
make build
docker compose up -d