forked from norman/fusionpbx-install.sh-github-mirror
Update fusionpbx.sh
This commit is contained in:
16
debian/resources/fusionpbx.sh
vendored
16
debian/resources/fusionpbx.sh
vendored
@@ -14,18 +14,18 @@ verbose "Installing FusionPBX"
|
|||||||
apt-get install -y --force-yes vim git dbus haveged ssl-cert
|
apt-get install -y --force-yes vim git dbus haveged ssl-cert
|
||||||
apt-get install -y --force-yes ghostscript libtiff5-dev libtiff-tools
|
apt-get install -y --force-yes ghostscript libtiff5-dev libtiff-tools
|
||||||
|
|
||||||
if [ .$USE_SYSTEM_MASTER = .true ]; then
|
if [ .$system_branch = "master" ]; then
|
||||||
verbose "Using master"
|
verbose "Using master"
|
||||||
BRANCH=""
|
branch=""
|
||||||
else
|
else
|
||||||
FUSION_MAJOR=$(git ls-remote --heads https://github.com/fusionpbx/fusionpbx.git | cut -d/ -f 3 | grep -P '^\d+\.\d+' | sort | tail -n 1 | cut -d. -f1)
|
system_major=$(git ls-remote --heads https://github.com/fusionpbx/fusionpbx.git | cut -d/ -f 3 | grep -P '^\d+\.\d+' | sort | tail -n 1 | cut -d. -f1)
|
||||||
FUSION_MINOR=$(git ls-remote --tags https://github.com/fusionpbx/fusionpbx.git $FUSION_MAJOR.* | cut -d/ -f3 | grep -P '^\d+\.\d+' | sort | tail -n 1 | cut -d. -f2)
|
system_minor=$(git ls-remote --tags https://github.com/fusionpbx/fusionpbx.git $system_major.* | cut -d/ -f3 | grep -P '^\d+\.\d+' | sort | tail -n 1 | cut -d. -f2)
|
||||||
FUSION_VERSION=$FUSION_MAJOR.$FUSION_MINOR
|
system_version=$system_major.$system_minor
|
||||||
verbose "Using version $FUSION_VERSION"
|
verbose "Using version $system_version"
|
||||||
BRANCH="-b $FUSION_VERSION"
|
branch="-b $system_version"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#get the source code
|
#get the source code
|
||||||
git clone $BRANCH https://github.com/fusionpbx/fusionpbx.git /var/www/fusionpbx
|
git clone $branch https://github.com/fusionpbx/fusionpbx.git /var/www/fusionpbx
|
||||||
chown -R www-data:www-data /var/www/fusionpbx
|
chown -R www-data:www-data /var/www/fusionpbx
|
||||||
chmod -R 755 /var/www/fusionpbx/secure
|
chmod -R 755 /var/www/fusionpbx/secure
|
||||||
|
|||||||
Reference in New Issue
Block a user