koopa-admin-log/scripts/cryptpad/build.sh
2026-09-09 00:52:54 +02:00

17 lines
648 B
Bash
Executable file

#!/usr/bin/env bash
# Build CryptPad image on CachyOS base (run on koopa).
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/../.." && pwd)"
CTX="${ROOT}/configs/cryptpad"
TAG="${IMAGE_TAG:-localhost/koopa-cryptpad:cachyos}"
CRYPTPAD_VERSION="${CRYPTPAD_VERSION:-2025.9.0}"
cd "$CTX"
[[ -f Containerfile ]] || { echo "ERROR: missing $CTX/Containerfile" >&2; exit 1; }
echo "build $TAG (CRYPTPAD_VERSION=$CRYPTPAD_VERSION) ctx=$CTX"
podman build \
--build-arg "CRYPTPAD_VERSION=${CRYPTPAD_VERSION}" \
-t "$TAG" \
-f Containerfile \
.
echo "OK: $TAG"
podman image inspect "$TAG" --format '{{.Id}} {{.Size}} {{.Architecture}}' 2>/dev/null || true