From 85007a892110a8ac8080cda56dfbb8cec58da9ac Mon Sep 17 00:00:00 2001 From: Steven Foerster Date: Sat, 30 May 2020 13:10:35 -0400 Subject: [PATCH 1/4] noninteractive script --- README.md | 12 ++++++++++++ scripts/noninteractive/.install_barebones | 2 ++ 2 files changed, 14 insertions(+) create mode 100644 scripts/noninteractive/.install_barebones diff --git a/README.md b/README.md index 88f3f9c..f25474d 100644 --- a/README.md +++ b/README.md @@ -141,6 +141,18 @@ Running `install.sh` will do the following: - copy Mistborn systemd service files to `/etc/systemd/system` - start and enable Mistborn-base +# Non-Interactive Installation +In order to install without interaction some environment variables need to be pre-set. + +## Environment Variables +See the environment variables needed in `./scripts/noninteractive/.install_barebones` + +## Install +``` +git clone https://gitlab.com/cyber5k/mistborn.git +sudo bash -c "source ./mistborn/scripts/noninteractive/.install_barebones && ./mistborn/scripts/install.sh" +``` + # Post-Installation When Mistborn-base starts up it will create volumes, initialize the PostgreSQL database, start pihole, run Django migrations and then check to see if a Mistborn superuser named `admin` exists yet. If not, it will create the superuser `admin` along with an accompanying default Wireguard configuration file and start the Wireguard service. You can watch all of this happen with: ``` diff --git a/scripts/noninteractive/.install_barebones b/scripts/noninteractive/.install_barebones new file mode 100644 index 0000000..c49be3c --- /dev/null +++ b/scripts/noninteractive/.install_barebones @@ -0,0 +1,2 @@ +MISTBORN_DEFAULT_PASSWORD=$(python3 -c "import secrets; import string; print(f''.join([secrets.choice(string.ascii_letters+string.digits) for x in range(20)]))") +MISTBORN_INSTALL_COCKPIT=No From 8f1999cd08ed0a69dae62c20845592dfc395ccb8 Mon Sep 17 00:00:00 2001 From: Steven Foerster Date: Sat, 30 May 2020 13:27:57 -0400 Subject: [PATCH 2/4] export --- scripts/noninteractive/.install_barebones | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/noninteractive/.install_barebones b/scripts/noninteractive/.install_barebones index c49be3c..48deb0e 100644 --- a/scripts/noninteractive/.install_barebones +++ b/scripts/noninteractive/.install_barebones @@ -1,2 +1,2 @@ -MISTBORN_DEFAULT_PASSWORD=$(python3 -c "import secrets; import string; print(f''.join([secrets.choice(string.ascii_letters+string.digits) for x in range(20)]))") -MISTBORN_INSTALL_COCKPIT=No +export MISTBORN_DEFAULT_PASSWORD=$(python3 -c "import secrets; import string; print(f''.join([secrets.choice(string.ascii_letters+string.digits) for x in range(20)]))") +export MISTBORN_INSTALL_COCKPIT=No From 24680a8f220e587caae63b220e812e498ed44953 Mon Sep 17 00:00:00 2001 From: Steven Foerster Date: Sat, 30 May 2020 13:48:13 -0400 Subject: [PATCH 3/4] re-order tested OSes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f25474d..8073a4e 100644 --- a/README.md +++ b/README.md @@ -44,8 +44,8 @@ Within Mistborn is a panel to enable and manage these free extra services (off b # Quickstart Tested Operating Systems (in order of thoroughness): -- Ubuntu 18.04 LTS - Ubuntu 20.04 LTS +- Ubuntu 18.04 LTS - Debian 10 (Buster) - Raspbian Buster From 1b7dd578746e720f1c05c93c402f013e98aa28ac Mon Sep 17 00:00:00 2001 From: Steven Foerster Date: Sat, 30 May 2020 14:02:03 -0400 Subject: [PATCH 4/4] README --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8073a4e..6c639e6 100644 --- a/README.md +++ b/README.md @@ -147,7 +147,8 @@ In order to install without interaction some environment variables need to be pr ## Environment Variables See the environment variables needed in `./scripts/noninteractive/.install_barebones` -## Install +## Example Noninteractive Install +This will perform a noninteractive install with the default environment variables set in `.install_barebones`. ``` git clone https://gitlab.com/cyber5k/mistborn.git sudo bash -c "source ./mistborn/scripts/noninteractive/.install_barebones && ./mistborn/scripts/install.sh"