From c690fcb6fe085fcfac4fe6e7023a9e014c7abe2b Mon Sep 17 00:00:00 2001 From: Marcel Stangenberger Date: Sat, 5 Apr 2025 10:11:03 +0200 Subject: [PATCH] New installation method --- README.md | 10 +++------- lab_config.json => pre/config.json | 0 pre/run.sh | 15 +++++++++++++++ users.crypt => pre/users.crypt | 0 4 files changed, 18 insertions(+), 7 deletions(-) rename lab_config.json => pre/config.json (100%) create mode 100644 pre/run.sh rename users.crypt => pre/users.crypt (100%) diff --git a/README.md b/README.md index 66357fe..a3bad2c 100644 --- a/README.md +++ b/README.md @@ -15,12 +15,8 @@ gpg --output user_credentials.json --decrypt user_credentials.crypt ### Usage 1. Boot from Arch Linux iso -2. Download the encrypted credentials file using curl +2. Run pre-install script ``` -curl -O https://git.xo.nl/marcel/archinstall/raw/master/users.crypt) +bash -c "$(curl -fsSL https://git.xoservice.nl/marcel/archlinux/raw/master/pre/run.sh)" ``` -3. Decrypt using above command -4. Run the archinstall command -``` -archinstall --config https://git.xo.nl/marcel/archinstall/raw/master/user_configuration.json --creds ./users.json --silent) -``` \ No newline at end of file +3. Follow any given steps diff --git a/lab_config.json b/pre/config.json similarity index 100% rename from lab_config.json rename to pre/config.json diff --git a/pre/run.sh b/pre/run.sh new file mode 100644 index 0000000..1b179df --- /dev/null +++ b/pre/run.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +REPO=https://git.xoservice.nl/marcel/archlinux + +curl -O $REPO/raw/master/pre/users.crypt +gpg --output users.json --decrypt users.crypt + +if test -s ./users.json; +then + archinstall --config $REPO/raw/master/pre/config.json --creds ./users.json --silent + reboot +else + echo "users.json not found in current directory or file is empty" + exit 1 +fi diff --git a/users.crypt b/pre/users.crypt similarity index 100% rename from users.crypt rename to pre/users.crypt