Skip to content

Commit 81a1170

Browse files
committed
change log
1 parent db5cc43 commit 81a1170

File tree

2 files changed

+38
-46
lines changed

2 files changed

+38
-46
lines changed

Install/customize_firmware.sh

+19-23
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ target=${target::-1}
1515
architecture=${architecture:1}
1616
target=${target:1}
1717

18-
1918
LOCALADDRESS="127.192.0.1/10"
2019

2120
actLoop=$(ifconfig | grep '^l\w*' -m 1 | cut -f1 -d ' ')
@@ -58,7 +57,6 @@ WAN_MOBILE_GW=$(echo $INET_GW | cut -f1 -d '.')
5857
WAN_MOBILE_GW=$WAN_ip'.'$(echo $INET_GW | cut -f2 -d '.')
5958
WAN_MOBILE_GW=$WAN_ip'.'$(echo $INET_GW | cut -f3 -d '.')'.253'
6059

61-
6260
#complet Internet
6361
Internet="0.0.0.0/0"
6462

@@ -117,9 +115,8 @@ check_download() {
117115
else
118116
# echo "Hash-Error"
119117
rm -f "$OUTPUT_FILE"
120-
fi
121-
fi
122-
118+
fi
119+
fi
123120
}
124121

125122
customize_firmware() {
@@ -171,14 +168,13 @@ uci set wireless.default_radio1.ssid='CyberSec-Box'
171168
uci set uhttpd.main.index_page='index.php'
172169
uci set uhttpd.main.interpreter='.php=/usr/bin/php-cgi'
173170
processes=$(uci commit && reload_config)
174-
wait $processes >> install.log
175-
/etc/init.d/uhttpd restart >> install.log
176-
/etc/init.d/network restart >> install.log
171+
wait $processes >> install_customice.log
172+
/etc/init.d/uhttpd restart >> install_customice.log
173+
/etc/init.d/network restart >> install_customice.log
177174
echo
178175
echo 'Default Country-Settings'
179176
echo
180177

181-
182178
echo
183179
echo 'https activated'
184180
echo
@@ -314,9 +310,9 @@ create_hotspot(){
314310
uci set wireless.radio0.country='DE'
315311
uci set wireless.radio0.channel='auto'
316312
uci set wireless.radio0.hwmode='11n'
317-
uci delete wireless.radio0.disabled >> install.log
313+
uci delete wireless.radio0.disabled >> install_customice.log
318314
processes=$(uci commit && reload_config)
319-
wait $processes >> install.log
315+
wait $processes >> install_customice.log
320316
if [ ! -d "$FILE" ]
321317
then
322318
create_hotspot_sub
@@ -418,35 +414,35 @@ set_uhttpd() {
418414
uci set uhttpd.main.index_page='index.php'
419415
uci set uhttpd.main.interpreter='.php=/usr/bin/php-cgi'
420416
processes=$(uci commit && reload_config)
421-
wait $processes >> install.log
417+
wait $processes >> install_customice.log
422418
}
423419

424420
#-------------------------start---------------------------------------
425421

426422
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...'
427-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...' >> install.log
423+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...' >> install_customice.log
428424
echo
429-
echo >> install.log
425+
echo >> install_customice.log
430426
echo $main_release
431427
echo
432428
echo 'Automation Install'
433429
echo
434-
echo >> install.log
430+
echo >> install_customice.log
435431
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware'
436-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware' >> install.log
437-
customize_firmware >> install.log
432+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware' >> install_customice.log
433+
customize_firmware >> install_customice.log
438434

439435
echo
440-
echo >> install.log
436+
echo >> install_customice.log
441437
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot'
442-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot' >> install.log
443-
create_hotspot >> install.log
438+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot' >> install_customice.log
439+
create_hotspot >> install_customice.log
444440

445441
echo
446-
echo >> install.log
442+
echo >> install_customice.log
447443
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd'
448-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd' >> install.log
449-
set_uhttpd >> install.log
444+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd' >> install_customice.log
445+
set_uhttpd >> install_customice.log
450446

451447
cat << EOF > /etc/rc.local
452448
if [ ! -f /root/openWRT23_install.sh ] && [ ! -f www/luci-static/bootstrap/cascade.css ]

customize_firmware.sh

+19-23
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ target=${target::-1}
1515
architecture=${architecture:1}
1616
target=${target:1}
1717

18-
1918
LOCALADDRESS="127.192.0.1/10"
2019

2120
actLoop=$(ifconfig | grep '^l\w*' -m 1 | cut -f1 -d ' ')
@@ -58,7 +57,6 @@ WAN_MOBILE_GW=$(echo $INET_GW | cut -f1 -d '.')
5857
WAN_MOBILE_GW=$WAN_ip'.'$(echo $INET_GW | cut -f2 -d '.')
5958
WAN_MOBILE_GW=$WAN_ip'.'$(echo $INET_GW | cut -f3 -d '.')'.253'
6059

61-
6260
#complet Internet
6361
Internet="0.0.0.0/0"
6462

@@ -117,9 +115,8 @@ check_download() {
117115
else
118116
# echo "Hash-Error"
119117
rm -f "$OUTPUT_FILE"
120-
fi
121-
fi
122-
118+
fi
119+
fi
123120
}
124121

125122
customize_firmware() {
@@ -171,14 +168,13 @@ uci set wireless.default_radio1.ssid='CyberSec-Box'
171168
uci set uhttpd.main.index_page='index.php'
172169
uci set uhttpd.main.interpreter='.php=/usr/bin/php-cgi'
173170
processes=$(uci commit && reload_config)
174-
wait $processes >> install.log
175-
/etc/init.d/uhttpd restart >> install.log
176-
/etc/init.d/network restart >> install.log
171+
wait $processes >> install_customice.log
172+
/etc/init.d/uhttpd restart >> install_customice.log
173+
/etc/init.d/network restart >> install_customice.log
177174
echo
178175
echo 'Default Country-Settings'
179176
echo
180177

181-
182178
echo
183179
echo 'https activated'
184180
echo
@@ -314,9 +310,9 @@ create_hotspot(){
314310
uci set wireless.radio0.country='DE'
315311
uci set wireless.radio0.channel='auto'
316312
uci set wireless.radio0.hwmode='11n'
317-
uci delete wireless.radio0.disabled >> install.log
313+
uci delete wireless.radio0.disabled >> install_customice.log
318314
processes=$(uci commit && reload_config)
319-
wait $processes >> install.log
315+
wait $processes >> install_customice.log
320316
if [ ! -d "$FILE" ]
321317
then
322318
create_hotspot_sub
@@ -418,35 +414,35 @@ set_uhttpd() {
418414
uci set uhttpd.main.index_page='index.php'
419415
uci set uhttpd.main.interpreter='.php=/usr/bin/php-cgi'
420416
processes=$(uci commit && reload_config)
421-
wait $processes >> install.log
417+
wait $processes >> install_customice.log
422418
}
423419

424420
#-------------------------start---------------------------------------
425421

426422
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...'
427-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...' >> install.log
423+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S':'%N) ' Starting...' >> install_customice.log
428424
echo
429-
echo >> install.log
425+
echo >> install_customice.log
430426
echo $main_release
431427
echo
432428
echo 'Automation Install'
433429
echo
434-
echo >> install.log
430+
echo >> install_customice.log
435431
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware'
436-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware' >> install.log
437-
customize_firmware >> install.log
432+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Customize Firmware' >> install_customice.log
433+
customize_firmware >> install_customice.log
438434

439435
echo
440-
echo >> install.log
436+
echo >> install_customice.log
441437
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot'
442-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot' >> install.log
443-
create_hotspot >> install.log
438+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Create Hotspot' >> install_customice.log
439+
create_hotspot >> install_customice.log
444440

445441
echo
446-
echo >> install.log
442+
echo >> install_customice.log
447443
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd'
448-
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd' >> install.log
449-
set_uhttpd >> install.log
444+
echo $(date +%d'.'%m'.'%y' '%H':'%M':'%S)' Set uhttpd' >> install_customice.log
445+
set_uhttpd >> install_customice.log
450446

451447
cat << EOF > /etc/rc.local
452448
if [ ! -f /root/openWRT23_install.sh ] && [ ! -f www/luci-static/bootstrap/cascade.css ]

0 commit comments

Comments
 (0)