From 9f3f014a84151a0d0c48c566a1301e65da7ab08a Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Sun, 13 Mar 2022 17:35:31 +0100 Subject: [PATCH] Add script to copy alpine linux installer and execute it --- copy-tools-and-install.sh | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100755 copy-tools-and-install.sh diff --git a/copy-tools-and-install.sh b/copy-tools-and-install.sh new file mode 100755 index 0000000..1434a55 --- /dev/null +++ b/copy-tools-and-install.sh @@ -0,0 +1,21 @@ +#!/bin/sh + +if [ $# -ne 4 ]; then + echo "$0 host [args for alpine-install-on-disk.sh]" + exit 1 +fi + +host=$1; shift + +disk=$1; shift +key=$1; shift +mode=$1; shift + +cat < /etc/resolv.conf +apk add git sfdisk sudo util-linux-misc wget +cd /opt +if [ ! -d /opt/ungleich-tools ]; then git clone https://code.ungleich.ch/ungleich-public/ungleich-tools.git; fi +/opt/ungleich-tools/alpine-install-on-disk.sh $disk $key $mode + +EOF