Skip to content

Commit 25839ed

Browse files
committed
[Changes] Service/Maintenance Page - Path Updates
new file: src/static/static/home/yi-hack-v5/etc/defaults.tar.bz2 modified: src/www/httpd/cgi-bin/load.sh modified: src/www/httpd/cgi-bin/reset.sh
1 parent 51c0ed9 commit 25839ed

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed
2.14 KB
Binary file not shown.

src/www/httpd/cgi-bin/load.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,12 @@ get_config()
1414
TMPOUT=/tmp/config.tar.bz2.dl
1515
TMPDIR=/tmp/workdir.tmp
1616
TMPOUTbz2=$TMPDIR/config.tar.bz2
17+
TMPOUTtar=$TMPDIR/config.tar
1718

1819
# Cleaning
1920
rm -f $TMPOUT
2021
rm -f $TMPOUTbz2
22+
rm -f $TMPOUTtar
2123
rm -rf $TMPDIR
2224

2325
mkdir -p $TMPDIR
@@ -61,7 +63,8 @@ fi
6163
LEN=$((CONTENT_LENGTH-LENSKIPSTART-LENSKIPEND+2))
6264
dd if=$TMPOUT of=$TMPOUTbz2 bs=1 skip=$LENSKIPSTART count=$LEN >/dev/null 2>&1
6365
cd $TMPDIR
64-
tar jxvf $TMPOUTbz2 >/dev/null 2>&1
66+
bzip2 -d $TMPOUTbz2
67+
tar xvf $TMPOUTtar >/dev/null 2>&1
6568
RES=$?
6669

6770
# Verify result of tar.bz2 command and copy files to destination

src/www/httpd/cgi-bin/reset.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ rm mqttv4.conf
99
rm proxychains.conf
1010
rm system.conf
1111

12-
tar jxvf defaults.tar.bz2 > /dev/null 2>&1
12+
bzip2 -d defaults.tar.bz2
13+
tar xvf defaults.tar > /dev/null 2>&1
1314

1415
printf "Content-type: application/json\r\n\r\n"
1516
printf "{\n"

0 commit comments

Comments
 (0)