Ensure lighttpd installed for ttyd

This commit is contained in:
Zach Brown
2024-04-10 12:42:49 +00:00
parent dc7f3f17d2
commit 315b937e8f
2 changed files with 6 additions and 2 deletions

View File

@@ -361,7 +361,7 @@ install_simple_admin() {
install_lighttpd
while true; do
echo -e "\e[1;32mWhat version of Simple Admin do you want to install? This will start a webserver on port 8080\e[0m"
echo -e "\e[1;32mWhat version of Simple Admin do you want to install? This will start a webserver on port 80/443\e[0m"
echo -e "\e[1;32m1) Stable current version, (Main Branch)\e[0m"
echo -e "\e[1;31m2) Install Test Build (Development Branch)\e[0m"
echo -e "\e[0;33m3) Return to Main Menu\e[0m"
@@ -888,6 +888,10 @@ install_ttyd() {
mount -o remount,rw /
if [ ! -d "/usrdata/lighttpd" ]; then
install_lighttpd
fi
if [ -d "/usrdata/ttyd" ]; then
echo -e "\e[1;34mttyd is already installed. Choose an option:\e[0m"
echo -e "\e[1;34m1.) Update to ttyd 1.7.5 (DO NOT UPDATE WHILE USING ttyd! Use ADB or SSH instead)\e[0m"

View File

@@ -43,5 +43,5 @@ $HTTP["url"] =~ "/cgi-bin/" {
# Handle proxy to ttyd if it's running
$HTTP["url"] =~ "(^/ttyd)" {
proxy.header = ("map-urlpath" => ( "/ttyd" => "/" ), "upgrade" => "enable" )
proxy.server = ( "" => ("" => ( "host" => "127.0.0.1", "port" => 8443 )))
proxy.server = ( "" => ("" => ( "host" => "127.0.0.1", "port" => 8088 )))
}