diff --git a/scripts/install.sh b/scripts/install.sh index b1dc9c0..a8197cf 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -86,6 +86,9 @@ pushd . cd /opt/mistborn git submodule update --init --recursive +# install figlet +sudo apt-get install -y figlet + # get os and distro source ./scripts/subinstallers/platform.sh @@ -133,7 +136,10 @@ source ./scripts/subinstallers/cockpit.sh # Mistborn # final setup vars iface=$(ip -o -4 route show to default | egrep -o 'dev [^ ]*' | awk '{print $2}') -IPV4_PUBLIC=$(ip -o -4 route show default | egrep -o 'dev [^ ]*' | awk '{print $2}' | xargs ip -4 addr show | grep 'inet ' | awk '{print $2}' | grep -o "^[0-9.]*" | tr -cd '\11\12\15\40-\176' | head -1) # tail -1 to get last +figlet "Mistborn default NIC: $iface" + +#IPV4_PUBLIC=$(ip -o -4 route show default | egrep -o 'dev [^ ]*' | awk '{print $2}' | xargs ip -4 addr show | grep 'inet ' | awk '{print $2}' | grep -o "^[0-9.]*" | tr -cd '\11\12\15\40-\176' | head -1) # tail -1 to get last +IPV4_PUBLIC="10.2.3.1" # clean if [ -f "/etc/systemd/system/Mistborn-base.service" ]; then @@ -216,3 +222,7 @@ sudo tar -czf ../mistborn_backup/mistborn_volumes_backup.tar.gz ../mistborn_volu sudo systemctl enable Mistborn-base.service sudo systemctl start Mistborn-base.service popd + +figlet "Mistborn Installed" +echo "Watch Mistborn start: sudo journalctl -xfu Mistborn-base" +echo "Retrieve Wireguard default config for admin: sudo docker-compose -f /opt/mistborn/base run --rm django python manage.py getconf admin default" diff --git a/scripts/subinstallers/cockpit.sh b/scripts/subinstallers/cockpit.sh index 98c376b..da90569 100755 --- a/scripts/subinstallers/cockpit.sh +++ b/scripts/subinstallers/cockpit.sh @@ -1,7 +1,7 @@ #!/bin/bash # Cockpit -echo "Installing Cockpit" +figlet "Mistborn: Installing Cockpit" if [ "$DISTRO" == "ubuntu" ]; then echo "Ubuntu backports enabled by default" diff --git a/scripts/subinstallers/docker.sh b/scripts/subinstallers/docker.sh index dbb4a2c..b962864 100755 --- a/scripts/subinstallers/docker.sh +++ b/scripts/subinstallers/docker.sh @@ -1,6 +1,8 @@ #!/bin/bash # Docker +figlet "Mistborn: Installing Docker" + # dependencies echo "Installing Docker dependencies" sudo apt-get install -y \ diff --git a/scripts/subinstallers/gen_prod_env.sh b/scripts/subinstallers/gen_prod_env.sh index dbd58f8..3848efc 100755 --- a/scripts/subinstallers/gen_prod_env.sh +++ b/scripts/subinstallers/gen_prod_env.sh @@ -1,5 +1,7 @@ #!/bin/sh +figlet "Mistborn: Container Credentials" + # generate production .env file for Django mkdir -p ./.envs/.production DJANGO_PROD_FILE="./.envs/.production/.django" diff --git a/scripts/subinstallers/iptables.sh b/scripts/subinstallers/iptables.sh index 750c899..208ec6a 100755 --- a/scripts/subinstallers/iptables.sh +++ b/scripts/subinstallers/iptables.sh @@ -2,6 +2,7 @@ set -e +figlet "Mistborn: Configuring Firewall" echo "stop iptables wrappers" if [ "$DISTRO" == "ubuntu" ]; then diff --git a/scripts/subinstallers/platform.sh b/scripts/subinstallers/platform.sh index 08e4c00..3c18fce 100755 --- a/scripts/subinstallers/platform.sh +++ b/scripts/subinstallers/platform.sh @@ -10,5 +10,5 @@ if [ "$UNAME" == "linux" ]; then DISTRO=$(cat /etc/os-release | awk -F= '/^ID=/{print $2}') fi -echo "UNAME: $UNAME" -echo "DISTRO: $DISTRO" +figlet "UNAME: $UNAME" +figlet "DISTRO: $DISTRO" diff --git a/scripts/subinstallers/wireguard.sh b/scripts/subinstallers/wireguard.sh index 358ebf4..d027f79 100755 --- a/scripts/subinstallers/wireguard.sh +++ b/scripts/subinstallers/wireguard.sh @@ -1,5 +1,7 @@ #!/bin/bash +figlet "Mistborn: Installing Wireguard" + # Wireguard if [ "$DISTRO" == "raspbian" ]; then echo "Adding Wireguard repo keys"