-
Notifications
You must be signed in to change notification settings - Fork 1
/
getbase.sh
executable file
·38 lines (28 loc) · 1.24 KB
/
getbase.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/bash
# LiveG OS Bootstrap Toolchain
#
# Copyright (C) LiveG. All Rights Reserved.
#
# https://liveg.tech/os
# Licensed by the LiveG Open-Source Licence, which can be found at LICENCE.md.
# TODO: Keep a local copy of the Debian base image — old versions get deleted after a while
mkdir -p cache/$PLATFORM
case $PLATFORM in
x86_64)
wget -nc https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/debian-12.7.0-amd64-netinst.iso -O cache/$PLATFORM/base.iso
;;
rpi)
wget -nc https://downloads.raspberrypi.com/raspios_lite_armhf/images/raspios_lite_armhf-2024-10-28/2024-10-22-raspios-bookworm-armhf-lite.img.xz -O cache/$PLATFORM/baseinstall.img.xz
if ! [ -e cache/$PLATFORM/baseinstall.img ]; then
xz -d -k cache/$PLATFORM/baseinstall.img.xz
fi
;;
arm64)
wget -nc https://cdimage.debian.org/debian-cd/current/arm64/iso-cd/debian-12.7.0-arm64-netinst.iso -O cache/$PLATFORM/base.iso
;;
pinephone)
wget -nc https://images.mobian.org/pinephone/mobian-pinephone-phosh-12.0.img.gz -O cache/$PLATFORM/baseinstall.img.gz
if ! [ -e cache/$PLATFORM/baseinstall.img ]; then
gzip -d cache/$PLATFORM/baseinstall.img.gz
fi
esac