]> BookStack Code Mirror - devops/commitdiff
Update installation-ubuntu-18.04.sh 15/head
authoraaronstuder <redacted>
Wed, 7 Nov 2018 22:47:07 +0000 (17:47 -0500)
committerGitHub <redacted>
Wed, 7 Nov 2018 22:47:07 +0000 (17:47 -0500)
Allows passing the domain as an argument. If missing asked as it did before.

scripts/installation-ubuntu-18.04.sh

index af398e6ccc6cb3b0ace34d3b096868832bd12943..64725bacf4bdd03972b298061e2cc8d125a4af8b 100644 (file)
@@ -2,9 +2,13 @@
 # This script will install a new BookStack instance on a fresh Ubuntu 18.04 server.
 # This script is experimental and does not ensure any security.
 
+DOMAIN=$1
+if [ -z $1 ]
+then
 echo ""
 printf "Enter the domain you want to host BookStack and press [ENTER]\nExamples: my-site.com or docs.my-site.com\n"
 read DOMAIN
+fi
 
 CURRENT_IP=$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1  -d'/')