Commit 440857fb authored by Daniel's avatar Daniel

Update overlay/root/scripts/nc_config.sh

parent 5f0af205
......@@ -2,15 +2,16 @@
echo "nextcloud: start setup"
. /root/scripts/_CONFIG_VARS_.sh
echo "nextcloud: setup php-fpm config"
echo; echo "nextcloud: setup php-fpm config"
# change /usr/local/etc/php-fpm.d/nextcloud.conf
# create a backup
cp ${file_php_fpm_nc_conf} "${file_php_fpm_nc_conf}.bkp"
change_config_value_by_vars ${file_php_fpm_nc_conf}
service php-fpm restart 1>/dev/null
sleep 5
echo "nextcloud: downloading and installing latest nextcloud package"
echo; echo "nextcloud: downloading and installing latest nextcloud package"
file_nc_tmp_zip=/tmp/nextcloud.zip
# cleanup
rm -r $dir_nextcloud
......@@ -18,11 +19,12 @@ rm -r $dir_nextcloud_data
rm -r $dir_nextcloud_sessions
#
# download latest release
wget -nv -O ${file_nc_tmp_zip} https://download.nextcloud.com/server/releases/latest.zip
if [ ! -f "$file_nc_tmp_zip" ]; then
wget -nv -O ${file_nc_tmp_zip} https://download.nextcloud.com/server/releases/latest.zip
fi
#
# unzip to www directory
unzip -q -d ${dir_www} ${file_nc_tmp_zip} 1>/dev/null
unzip -q -d ${dir_www} ${file_nc_tmp_zip}
#
# create sessions tmp dir outside nextcloud installation
mkdir -p ${dir_nextcloud_sessions}
......@@ -38,7 +40,7 @@ fi
. /root/scripts/nc_restore_permissions.sh
echo "nextcloud: setup via occ"
echo; echo "nextcloud: setup via occ"
# https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/occ_command.html#command-line-installation
# https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/occ_command.html
# Use occ to complete Nextcloud installation
......@@ -53,7 +55,7 @@ occ config:system:set logfile. --value "/var/log/nextcloud/nextcloud.log"
occ config:system:set logfilemode --value "0640"
echo "nextcloud: setup cronjob"
echo; echo "nextcloud: setup cronjob"
# https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/background_jobs_configuration.html
#https://www.golinuxcloud.com/create-schedule-cron-job-shell-script-linux/
# create dir and permissions
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment