Fix duplicated location after wo upgrade
This commit is contained in:
16
install
16
install
@@ -7,10 +7,10 @@
|
||||
# Copyright (c) 2019 - WordOps
|
||||
# This script is licensed under M.I.T
|
||||
# -------------------------------------------------------------------------
|
||||
# Version 3.9.5.3 - 2019-06-18
|
||||
# Version 3.9.5.4 - 2019-07-09
|
||||
# -------------------------------------------------------------------------
|
||||
readonly wo_version_old="2.2.3"
|
||||
readonly wo_version_new="3.9.5.3"
|
||||
readonly wo_version_new="3.9.5.4"
|
||||
# CONTENTS
|
||||
# ---
|
||||
# 1. VARIABLES AND DECLARATIONS
|
||||
@@ -178,14 +178,10 @@ wo_install_dep() {
|
||||
DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y dist-upgrade
|
||||
} > /dev/null 2>&1
|
||||
if [ "$wo_linux_distro" == "Ubuntu" ]; then
|
||||
# add nginx repository gpg key
|
||||
wget https://download.opensuse.org/repositories/home:virtubox:WordOps/xUbuntu_"$wo_distro_id"/Release.key -O Release.key
|
||||
apt-key add - < Release.key
|
||||
rm -f Release.key
|
||||
# install dependencies
|
||||
DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y install build-essential curl gzip python3 python3-apt python3-setuptools python3-dev sqlite3 git tar software-properties-common pigz gnupg2 cron ccze rsync tree haveged ufw > /dev/null 2>&1
|
||||
else
|
||||
# add nginx repository gpg ke
|
||||
# add nginx repository gpg key
|
||||
wget https://download.opensuse.org/repositories/home:virtubox:WordOps/Debian_9.0/Release.key -O Release.key
|
||||
apt-key add - < Release.key
|
||||
rm -f Release.key
|
||||
@@ -344,7 +340,7 @@ wo_update_wp_cli() {
|
||||
[ ! -h /usr/bin/wp ] && {
|
||||
ln -s /usr/local/bin/wp /usr/bin/
|
||||
}
|
||||
[ ! -f /etc/bash_completion.d/wp-completion.bash ] && {
|
||||
[ -d /etc/bash_completion.d ] && {
|
||||
wget -qO /etc/bash_completion.d/wp-completion.bash https://raw.githubusercontent.com/wp-cli/wp-cli/master/utils/wp-completion.bash
|
||||
}
|
||||
} >> "$wo_install_log" 2>&1
|
||||
@@ -491,6 +487,10 @@ wo_upgrade_nginx() {
|
||||
|
||||
# restore sites and configuration
|
||||
/usr/bin/rsync -auz /var/lib/wo-backup/nginx/ /etc/nginx/
|
||||
sed -i "s/locations.conf/locations-wo.conf/" /etc/nginx/sites-available/*
|
||||
sed -i "s/locations-php7.conf/locations-wo.conf/" /etc/nginx/sites-available/*
|
||||
sed -i "s/locations-php72.conf/locations-wo.conf/" /etc/nginx/sites-available/*
|
||||
sed -i "s/locations-php73.conf/locations-wo.conf/" /etc/nginx/sites-available/*
|
||||
|
||||
# update redis.conf headers
|
||||
if [ -f /etc/nginx/common/redis.conf ]; then
|
||||
|
||||
Reference in New Issue
Block a user