mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-14 10:37:39 -07:00
Update vst-install-ubuntu.sh
- Added to help function for ssl - Added argument for enabling Let's Encrypt SSL - Added set_default_value 'ssl' 'no' - Install Let's Encrypt on hostname, update certificate, and enable auto-renew if 'ssl' argument is 'yes'
This commit is contained in:
parent
7c9afbca32
commit
f8734d15e9
1 changed files with 11 additions and 0 deletions
|
@ -61,6 +61,7 @@ help() {
|
|||
-l, --lang Default language default: en
|
||||
-y, --interactive Interactive install [yes|no] default: yes
|
||||
-s, --hostname Set hostname
|
||||
-u, --ssl Add LE SSL for hostname [yes|no] default: no
|
||||
-e, --email Set admin email
|
||||
-p, --password Set admin password
|
||||
-f, --force Force installation
|
||||
|
@ -149,6 +150,7 @@ for arg; do
|
|||
--lang) args="${args}-l " ;;
|
||||
--interactive) args="${args}-y " ;;
|
||||
--hostname) args="${args}-s " ;;
|
||||
--ssl) args="${args}-u " ;;
|
||||
--email) args="${args}-e " ;;
|
||||
--password) args="${args}-p " ;;
|
||||
--force) args="${args}-f " ;;
|
||||
|
@ -183,6 +185,7 @@ while getopts "a:n:w:v:j:k:m:g:d:x:z:c:t:i:b:r:o:q:l:y:s:e:p:fh" Option; do
|
|||
l) lang=$OPTARG ;; # Language
|
||||
y) interactive=$OPTARG ;; # Interactive install
|
||||
s) servername=$OPTARG ;; # Hostname
|
||||
u) ssl=$OPTARG ;; # Add Let's Encrypt SSL for hostname
|
||||
e) email=$OPTARG ;; # Admin email
|
||||
p) vpass=$OPTARG ;; # Admin password
|
||||
f) force='yes' ;; # Force install
|
||||
|
@ -215,6 +218,7 @@ set_default_value 'fail2ban' 'yes'
|
|||
set_default_value 'softaculous' 'yes'
|
||||
set_default_value 'quota' 'no'
|
||||
set_default_value 'interactive' 'yes'
|
||||
set_default_value 'ssl' 'no'
|
||||
set_default_lang 'en'
|
||||
|
||||
# Checking software conflicts
|
||||
|
@ -1299,6 +1303,13 @@ $VESTA/upd/add_notifications.sh
|
|||
# Adding cronjob for autoupdates
|
||||
$VESTA/bin/v-add-cron-vesta-autoupdate
|
||||
|
||||
# Add Let's Encrypt SSL for hostname and enable auto-renew
|
||||
if [ "$ssl" = 'yes' ]; then
|
||||
$VESTA/bin/v-add-letsencrypt-domain 'admin' $(hostname) '' 'yes'
|
||||
$VESTA/bin/v-update-host-certificate admin $(hostname)
|
||||
echo "UPDATE_HOSTNAME_SSL='yes'" >> $VESTA/conf/vesta.conf
|
||||
fi
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Vesta Access Info #
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue