From 315b937e8f0dfff623cc64d6d6a953c63fff46eb Mon Sep 17 00:00:00 2001 From: Zach Brown Date: Wed, 10 Apr 2024 12:42:49 +0000 Subject: [PATCH] Ensure lighttpd installed for ttyd --- RMxxx_rgmii_toolkit.sh | 6 +++++- lighttpd/lighttpd.conf | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/RMxxx_rgmii_toolkit.sh b/RMxxx_rgmii_toolkit.sh index 702d95b..8f95250 100644 --- a/RMxxx_rgmii_toolkit.sh +++ b/RMxxx_rgmii_toolkit.sh @@ -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" diff --git a/lighttpd/lighttpd.conf b/lighttpd/lighttpd.conf index 306aadf..ea60e50 100644 --- a/lighttpd/lighttpd.conf +++ b/lighttpd/lighttpd.conf @@ -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 ))) }