mirror of https://github.com/tteck/Proxmox.git
finished
This commit is contained in:
parent
447b00663e
commit
37a814a052
|
@ -73,7 +73,7 @@ function update_script() {
|
||||||
exit
|
exit
|
||||||
;;
|
;;
|
||||||
2)
|
2)
|
||||||
if NEWTOKEN=$(whiptail --passwordbox "Setup your ADMIN-TOKEN (make it strong)" 10 58 3>&1 1>&2 2>&3); then
|
if NEWTOKEN=$(whiptail --passwordbox "Setup your ADMIN_TOKEN (make it strong)" 10 58 3>&1 1>&2 2>&3); then
|
||||||
if [[ -z "$NEWTOKEN" ]]; then exit-script; fi
|
if [[ -z "$NEWTOKEN" ]]; then exit-script; fi
|
||||||
ADMINTOKEN=$(echo -n ${NEWTOKEN} | argon2 "$(openssl rand -base64 32)" -e -id -k 19456 -t 2 -p 1)
|
ADMINTOKEN=$(echo -n ${NEWTOKEN} | argon2 "$(openssl rand -base64 32)" -e -id -k 19456 -t 2 -p 1)
|
||||||
if [[ -f /var/lib/vaultwarden/config.json ]]; then
|
if [[ -f /var/lib/vaultwarden/config.json ]]; then
|
||||||
|
|
|
@ -19,18 +19,14 @@ $STD apk add openssl
|
||||||
$STD apk add argon2
|
$STD apk add argon2
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
if NEWTOKEN=$(whiptail --passwordbox "Setup your ADMIN-TOKEN (make it strong)" 10 58 3>&1 1>&2 2>&3); then
|
if NEWTOKEN=$(whiptail --passwordbox "Setup your ADMIN_TOKEN (make it strong)" 10 58 3>&1 1>&2 2>&3); then
|
||||||
if [[ -z "$NEWTOKEN" ]]; then
|
if [[ -z "$NEWTOKEN" ]]; then
|
||||||
clear
|
clear
|
||||||
echo -e "⚠ User didn't setup ADMIN-TOKEN, Vaultwarden will not work until setup! \n"
|
echo -e "⚠ User didn't setup ADMIN_TOKEN, admin panel is disabled! \n"
|
||||||
echo -e "► Can be fixed by running the script inside the LXC! \n"
|
|
||||||
exit
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
clear
|
clear
|
||||||
echo -e "⚠ User didn't setup ADMIN-TOKEN, Vaultwarden will not work until setup! \n"
|
echo -e "⚠ User didn't setup ADMIN_TOKEN, admin panel is disabled! \n"
|
||||||
echo -e "► Can be fixed by running the script inside the LXC! \n"
|
|
||||||
exit
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
msg_info "Installing Alpine-Vaultwarden"
|
msg_info "Installing Alpine-Vaultwarden"
|
||||||
|
|
Loading…
Reference in New Issue