mirror of
https://github.com/flynx/proxmox-utils.git
synced 2025-10-28 18:50:08 +00:00
Compare commits
No commits in common. "2ffd4b91a9b032c4a17a75a2fdbb87dcd58da55f" and "342f4962938715b5c6139b23c50ef210d07d1f7d" have entirely different histories.
2ffd4b91a9
...
342f496293
@ -287,10 +287,12 @@ xreadpass(){
|
||||
local PASS2
|
||||
for attempt in 1 2 3 ; do
|
||||
read -sep "${prefix}${msg}password (Enter to skip): " PASS1
|
||||
echo
|
||||
if [ -z $PASS1 ] ; then
|
||||
return
|
||||
fi
|
||||
read -sep "${prefix}retype password: " PASS2
|
||||
echo
|
||||
if [[ $PASS1 != $PASS2 ]] ; then
|
||||
echo "ERROR: passwords do not match." >&2
|
||||
continue
|
||||
|
||||
@ -44,7 +44,6 @@ REBOOT=${REBOOT:=1}
|
||||
|
||||
# XXX should we ask??
|
||||
COLLABORA_OFFICE=${COLLABORA_OFFICE:=1}
|
||||
NEXTCLOUD_UPGRADE=${NEXTCLOUD_UPGRADE:=1}
|
||||
|
||||
readVars
|
||||
|
||||
@ -118,10 +117,6 @@ done
|
||||
sed -z -i \
|
||||
-e \"s/\\(trusted_domains[^)]*\\)/\\1${ADDRS}/\" \
|
||||
/var/www/nextcloud/config/config.php"
|
||||
@ lxc-attach $ID -- bash -c "\
|
||||
sed -i \
|
||||
-e '/^\$CONFIG =/ a\ '\''opcache.interned_strings_buffer'\'' => 32,' \
|
||||
/var/www/nextcloud/config/config.php"
|
||||
|
||||
# remove /index.php from urls...
|
||||
# for more info see:
|
||||
@ -132,17 +127,10 @@ done
|
||||
/var/www/nextcloud/config/config.php"
|
||||
@ lxc-attach $ID -- turnkey-occ maintenance:update:htaccess
|
||||
|
||||
|
||||
echo "# Copying assets..."
|
||||
pctPushAssets $ID
|
||||
# XXX need to push proxy config to gate...
|
||||
|
||||
#if ! [ -z $NEXTCLOUD_UPGRADE ] ; then
|
||||
# echo "# Upgrade nextcloud..."
|
||||
# # XXX ERR need to install update before...
|
||||
# @ lxc-attach $ID -- turnkey-occ upgrade
|
||||
#fi
|
||||
|
||||
# Colabora...
|
||||
if ! [ -z $COLLABORA_OFFICE ] ; then
|
||||
echo "# Collabora office..."
|
||||
@ -154,27 +142,26 @@ if ! [ -z $COLLABORA_OFFICE ] ; then
|
||||
&& wget https://collaboraoffice.com/downloads/gpg/collaboraonline-release-keyring.gpg"
|
||||
@ lxc-attach $ID -- bash -c "\
|
||||
apt update \
|
||||
&& apt install -y coolwsd code-brand"
|
||||
&& apt install coolwsd code-brand"
|
||||
# XXX should these be set in here or as args in the coolwsd.service ???
|
||||
# /etc/coolwsd/coolwsd.xml
|
||||
# ssl>enable -> false
|
||||
@ lxc-attach $ID -- bash -c "\
|
||||
sed -i \
|
||||
'/<ssl /,+5{ s/\(<enable [^>]*>\)true\(<\/enable>\)/\1false\2/ }' \
|
||||
'/<ssl /,+5{ s/\(<enable [^>]*>\)true\(</enable>\)/\1false\2/ }' \
|
||||
/etc/coolwsd/coolwsd.xml"
|
||||
# ssl>termination -> true
|
||||
@ lxc-attach $ID -- bash -c "\
|
||||
sed -i \
|
||||
'/<ssl /,+5{ s/\(<termination [^>]*>\)false\(<\/termination>\)/\1true\2/ }' \
|
||||
'/<ssl /,+5{ s/\(<termination [^>]*>\)false\(</termination>\)/\1true\2/ }' \
|
||||
/etc/coolwsd/coolwsd.xml"
|
||||
@ lxc-attach $ID -- systemctl restart coolwsd
|
||||
@ lxc-attach $ID -- systemctl restart coolswd
|
||||
|
||||
# apache2...
|
||||
@ lxc-attach $ID -- a2enmod \
|
||||
proxy \
|
||||
proxy_http \
|
||||
proxy_connect \
|
||||
proxy_wstunnel
|
||||
@ lxc-attach $ID -- a2enmod proxy
|
||||
@ lxc-attach $ID -- a2enmod proxy_http
|
||||
@ lxc-attach $ID -- a2enmod proxy_connect
|
||||
@ lxc-attach $ID -- a2enmod proxy_wstunnel
|
||||
# XXX TEST...
|
||||
@ lxc-attach $ID -- bash -c "\
|
||||
sed -i \
|
||||
@ -186,12 +173,12 @@ if ! [ -z $COLLABORA_OFFICE ] ; then
|
||||
|
||||
# nextcloud...
|
||||
@ lxc-attach $ID -- turnkey-occ app:install richdocuments
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set --value yes richdocuments disable_certificate_verification
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set --value "https://${APP_DOMAIN}" richdocuments public_wopi_url
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set --value "https://${APP_DOMAIN}" richdocuments wopi_url
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set richdocuments disable_certificate_verification yes
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set richdocuments public_wopi_url "https://${APP_DOMAIN}"
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set richdocuments wopi_url "https://${APP_DOMAIN}"
|
||||
# XXX do we need to set this differently???
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set --value prevent_group_restriction richdocuments types
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set --value yes richdocuments enabled
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set richdocuments types prevent_group_restriction
|
||||
@ lxc-attach $ID -- turnkey-occ config:app:set richdocuments enabled yes
|
||||
fi
|
||||
|
||||
echo "# Disabling fail2ban..."
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user