mirror of https://github.com/tteck/Proxmox.git
cert renewal option
This commit is contained in:
parent
7196373fae
commit
5968af5ceb
|
@ -61,9 +61,10 @@ function update_script() {
|
||||||
fi
|
fi
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/nextcloud/server/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
RELEASE=$(curl -s https://api.github.com/repos/nextcloud/server/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
||||||
while true; do
|
while true; do
|
||||||
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 2 \
|
CHOICE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 3 \
|
||||||
"1" "Update Nextcloud to $RELEASE" ON \
|
"1" "Update Nextcloud to $RELEASE" ON \
|
||||||
"2" "Nextcloud Credentials" OFF \
|
"2" "Nextcloud Credentials" OFF \
|
||||||
|
"3" "Renew selfsigned Certificate" OFF \
|
||||||
3>&1 1>&2 2>&3)
|
3>&1 1>&2 2>&3)
|
||||||
exit_status=$?
|
exit_status=$?
|
||||||
if [ $exit_status == 1 ]; then
|
if [ $exit_status == 1 ]; then
|
||||||
|
@ -88,6 +89,10 @@ function update_script() {
|
||||||
cat nextcloud.creds
|
cat nextcloud.creds
|
||||||
exit
|
exit
|
||||||
;;
|
;;
|
||||||
|
3)
|
||||||
|
$STD openssl req -x509 -nodes -days 365 -newkey rsa:4096 -keyout /etc/ssl/private/nextcloud-selfsigned.key -out /etc/ssl/certs/nextcloud-selfsigned.crt -subj "/C=US/O=Nextcloud/OU=Domain Control Validated/CN=nextcloud.local"
|
||||||
|
exit
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
|
@ -171,7 +171,7 @@ $STD rc-update add redis
|
||||||
$STD rc-service redis start
|
$STD rc-service redis start
|
||||||
msg_ok "Set up PHP-opcache + Redis"
|
msg_ok "Set up PHP-opcache + Redis"
|
||||||
|
|
||||||
msg_info "Setting up Nextcloud-Cron"
|
msg_info "Setting up Nextcloud-Cronjob"
|
||||||
mkdir -p /etc/periodic/5min
|
mkdir -p /etc/periodic/5min
|
||||||
cat <<'EOF' >/etc/periodic/5min/nextcloud_cron
|
cat <<'EOF' >/etc/periodic/5min/nextcloud_cron
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
@ -182,7 +182,7 @@ if rc-service nextcloud -q status >/dev/null 2>&1; then
|
||||||
fi
|
fi
|
||||||
EOF
|
EOF
|
||||||
sed -i '/monthly/a */5 * * * * run-parts /etc/periodic/5min' /etc/crontabs/root
|
sed -i '/monthly/a */5 * * * * run-parts /etc/periodic/5min' /etc/crontabs/root
|
||||||
msg_ok "Set up Nextcloud-Cron"
|
msg_ok "Set up Nextcloud-Cronjob"
|
||||||
|
|
||||||
msg_info "Setting up Nextcloud-Config"
|
msg_info "Setting up Nextcloud-Config"
|
||||||
cat <<'EOF' >/usr/share/webapps/nextcloud/config/config.php
|
cat <<'EOF' >/usr/share/webapps/nextcloud/config/config.php
|
||||||
|
|
Loading…
Reference in New Issue