Hi everybody. New to LE and Kodi.
I have spent three days breaking my head against the wall with no luck, trying to enable webserver on my LE (tried both 11.0.3 and 10.0.4) on Raspberry Pi 4.
I don't have the keyboard - only my laptop for ssh access. Thus for configuring kodi I wanted to enable http server, connect via Yatse android app and configure the rest (wifi, addons etc.)
Trying to follow the the wiki: https://kodi.wiki/view/Web_interface I have enabled ssh, stopped kodi systemd service and tried directly modifying webserver-related part of /storage/.kodi/userdata/guisettings.xml :
...
<setting id="services.webserver">true</setting>
<setting id="services.webserverport" default="true">8080</setting>
<setting id="services.webserverauthentication" default="true">true</setting>
<setting id="services.webserverusername" default="true">kodi</setting>
<setting id="services.webserverpassword" default="true" />
<setting id="services.webserverssl" default="true">false</setting>
<setting id="services.webskin" default="true">webinterface.default</setting>
<setting id="services.esenabled" default="true">true</setting>
<setting id="services.esport" default="true">9777</setting>
<setting id="services.esportrange" default="true">10</setting>
<setting id="services.esmaxclients" default="true">20</setting>
<setting id="services.esallinterfaces">true</setting>
....
Display More
After doing systemctl start kodi all was overwritten and nothing listens on ports 8080 or 9090.
Ok, then I have created /storage/.kodi/userdata/advancedsettings.xml with the following content:
<advancedsettings>
<services>
<esallinterfaces>true</esallinterfaces>
<webserver>true</webserver>
<zeroconf>true</zeroconf>
<webserverport>8080</webserverport>
</services>
</advancedsettings>
Expectations: Webserver starts listening on port 8080 for HTTP requests (so I could connect to it via Yatse Android client)
Actual results: JSON-RCP starts listening on 9090 but NOTHING is listening on 8080 (checking with nmap and netstat
PORT STATE SERVICE
80/tcp filtered http
8000/tcp filtered http-alt
8080/tcp filtered http-proxy
9090/tcp open zeus-admin
LibreELEC:~ # netstat -tulpn | grep 9090
tcp 0 0 0.0.0.0:9090 0.0.0.0:* LISTEN 6001/kodi.bin
tcp 0 0 :::9090 :::* LISTEN 6001/kodi.bin
LibreELEC:~ # netstat -tulpn | grep 8080
LibreELEC:~ #
Display More
Both LE11.0.3 and 10.0.4 show same behavior. I even tried to configure it with JSON-RCP (without luck) using the following curls (following by systemctl restart kodi)
❯ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "method": "JSONRPC.Version", "id": 1}' ws://192.168.2.2:9090/jsonrpc
❯ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "
method": "Settings.SetSettingValue", "params": {"setting": "services.webserverport", "value": 8080}, "id": 1}' ws://192.168.2.2:9090/jsonrpc
❯ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "
method": "Settings.SetSettingValue", "params": {"setting": "services.webserver", "value": true}, "id": 1}' ws://192.168.2.2:9090/jsonrpc
❯ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "
method": "Settings.SetSettingValue", "params": {"setting": "services.esallinterfaces", "value": true}, "id": 1}' ws://192.168.2.2:9090/jsonrpc
❯ curl -X POST -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "
method": "Settings.SetSettingValue", "params": {"setting": "services.zeroconf", "value": true}, "id": 1}' ws://192.168.2.2:9090/jsonrpc
Display More
I think I am missing something obvious, but cannot find anything online. I'd appreciate any help. Thanks.