feat(install): detect and display host architecture (amd64/arm64)
Uses uname -m to detect x86_64/aarch64 and maps to the OCI arch name. Printed at startup so users can confirm the correct image variant will be pulled. Fails early on unsupported architectures. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
c1158e9938
commit
fe90753a37
1 changed files with 8 additions and 0 deletions
|
|
@ -38,6 +38,14 @@ done
|
||||||
|
|
||||||
[[ $EUID -eq 0 ]] || die "must run as root"
|
[[ $EUID -eq 0 ]] || die "must run as root"
|
||||||
|
|
||||||
|
# ── architecture detection ───────────────────────────────────────────────
|
||||||
|
case "$(uname -m)" in
|
||||||
|
x86_64) ARCH=amd64 ;;
|
||||||
|
aarch64) ARCH=arm64 ;;
|
||||||
|
*) die "unsupported architecture: $(uname -m) (supported: x86_64, aarch64)" ;;
|
||||||
|
esac
|
||||||
|
info "architecture: linux/$ARCH"
|
||||||
|
|
||||||
# ── runtime detection ────────────────────────────────────────────────────
|
# ── runtime detection ────────────────────────────────────────────────────
|
||||||
if command -v podman-compose >/dev/null 2>&1; then
|
if command -v podman-compose >/dev/null 2>&1; then
|
||||||
COMPOSE=(podman-compose)
|
COMPOSE=(podman-compose)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue