Update scripts/alpine_boostrap.sh

This commit is contained in:
2026-01-14 18:47:32 +00:00
parent 142fc76c55
commit 423d5c8f5f

View File

@@ -1,6 +1,23 @@
#!/bin/bash
set -e
if [ "$EUID" -ne 0 ]; then
echo "Error: This script must be run as root" >&2
exit 1
fi
if [ ! -d "/var/lib/matchbox/assets" ]; then
echo "Error: Folder /var/lib/matchbox/assets does not exist." >&2
exit 1
fi
if ! curl -sSL -o /var/lib/matchbox/assets/vmlinuz https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/x86_64/netboot/vmlinuz-lts; then
echo "Error: Failed to download alpine vmlinuz." >&2
exit 1
fi
if ! curl -sSL -o /var/lib/matchbox/assets/initramfs https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/x86_64/netboot/initramfs-lts; then
echo "Error: Failed to download alpine initramfs." >&2
exit 1
fi