I’m having a webserver that exposes two ports:
443
(app A) (regular http)9630
(app B) (websocket)
A custom domain dev.my-app.com
is used for the webserver.
I can access both apps via corresponding ports and the domain name from webserver:
- https://dev.my-app.com
- https://dev.my-app.com:9630
I have configured my Iphone to use a tinyproxy
proxy:
- Iphone (
192.168.0.200
) - Webserver (
192.168.0.94
)
by setting host to 192.168.0.94
and port 8888
in the settings.
Iphone and the Webserver are in the same network.
The webserver is accessible via https://dev.myapp.com on phone browser. The proxy works correctly and I can see the page, however websockets are not working.
I have checked whether I can access the UI of app B
on phone and after accepting the non secure traffic I’m trapped in some kind of redirection loop. After I killed the browser and launched it again none of the URLS are working. (had to remove the safari cache to make it work again)
tinyproxy.conf
User nobody Group nobody Port 8888 Bind 0.0.0.0 Timeout 600 DefaultErrorFile "/home/linuxbrew/.linuxbrew/Cellar/tinyproxy/1.11.0/share/tinyproxy/default.html" StatFile "/home/linuxbrew/.linuxbrew/Cellar/tinyproxy/1.11.0/share/tinyproxy/stats.html" LogLevel Info MaxClients 100 ViaProxyName "tinyproxy" ConnectPort 9630 ConnectPort 8080 ConnectPort 3000 ConnectPort 443 ConnectPort 563
The question is how to correctly proxy the traffic from the phone to two apps that run on different ports using tinyproxy
?