Skip to content

Commit 5f0798a

Browse files
committed
Implement phpmyadmin update function to get the latest version.
1 parent 3559ad1 commit 5f0798a

File tree

2 files changed

+54
-0
lines changed

2 files changed

+54
-0
lines changed

install/hst-install-debian.sh

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ os='debian'
1717
release=$(cat /etc/debian_version|grep -o [0-9]|head -n1)
1818
codename="$(cat /etc/os-release |grep VERSION= |cut -f 2 -d \(|cut -f 1 -d \))"
1919
hestiacp="$HESTIA/install/$VERSION/$release"
20+
pma_v='4.8.3'
2021

2122
if [ "$release" -eq 9 ]; then
2223
software="nginx apache2 apache2-utils apache2-suexec-custom
@@ -1089,6 +1090,32 @@ if [ "$mysql" = 'yes' ]; then
10891090
chmod 777 /var/lib/phpmyadmin/tmp
10901091
fi
10911092

1093+
1094+
#----------------------------------------------------------#
1095+
# Update phpMyAdmin #
1096+
#----------------------------------------------------------#
1097+
1098+
# Download latest phpmyadmin release
1099+
wget https://files.phpmyadmin.net/phpMyAdmin/$pma_v/phpMyAdmin-$pma_v-all-languages.tar.gz
1100+
1101+
# Unpack files
1102+
tar xzf phpMyAdmin-$pma_v-all-languages.tar.gz
1103+
1104+
# Delete file to prevent error
1105+
if [ "$pma_#----------------------------------------------------------#
1106+
# Update phpMyAdmin #
1107+
v" = '4.8.3' ]; then
1108+
rm -fr /usr/share/phpmyadmin/doc/html
1109+
fi
1110+
1111+
# Overwrite old files
1112+
cp -rf phpMyAdmin-$pma_v-all-languages/* /usr/share/phpmyadmin
1113+
1114+
# Clear Up
1115+
rm -fr phpMyAdmin-$pma_v-all-languages
1116+
rm -f phpMyAdmin-$pma_v-all-languages.tar.gz
1117+
1118+
10921119
#----------------------------------------------------------#
10931120
# Configure PostgreSQL #
10941121
#----------------------------------------------------------#

install/hst-install-ubuntu.sh

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ os='ubuntu'
1717
release="$(lsb_release -s -r)"
1818
codename="$(lsb_release -s -c)"
1919
hestiacp="$HESTIA/install/$VERSION/$release"
20+
pma_v='4.8.3'
2021

2122
# Defining software pack for all distros
2223
software="apache2 apache2.2-common apache2-suexec-custom apache2-utils
@@ -1089,6 +1090,32 @@ if [ "$mysql" = 'yes' ]; then
10891090
chmod 777 /var/lib/phpmyadmin/tmp
10901091
fi
10911092

1093+
1094+
#----------------------------------------------------------#
1095+
# Update phpMyAdmin #
1096+
#----------------------------------------------------------#
1097+
1098+
# Download latest phpmyadmin release
1099+
wget https://files.phpmyadmin.net/phpMyAdmin/$pma_v/phpMyAdmin-$pma_v-all-languages.tar.gz
1100+
1101+
# Unpack files
1102+
tar xzf phpMyAdmin-$pma_v-all-languages.tar.gz
1103+
1104+
# Delete file to prevent error
1105+
if [ "$pma_#----------------------------------------------------------#
1106+
# Update phpMyAdmin #
1107+
v" = '4.8.3' ]; then
1108+
rm -fr /usr/share/phpmyadmin/doc/html
1109+
fi
1110+
1111+
# Overwrite old files
1112+
cp -rf phpMyAdmin-$pma_v-all-languages/* /usr/share/phpmyadmin
1113+
1114+
# Clear Up
1115+
rm -fr phpMyAdmin-$pma_v-all-languages
1116+
rm -f phpMyAdmin-$pma_v-all-languages.tar.gz
1117+
1118+
10921119
#----------------------------------------------------------#
10931120
# Configure PostgreSQL #
10941121
#----------------------------------------------------------#

0 commit comments

Comments
 (0)