Issue getting access through wwan0 to flask server

I have a flask server (on RPI4B) that runs over wifi, but need to use an IoT network due to an upcoming remote installation. Traditionally, I’ve always the flask server with app.run(host=’0.0.0.0’ port=5000)

I’ve installed a 3G/4G&LTE Base HAT, and can access the rpm via wlan0 but not wwan0.

The 3G/4G&LTE Hat is installed in ECM mode, and I can ping sixfab.com successfully from it (“ping -I wwan0 -c 5 sixfab.com”) returns 5 responses without error/

I’ve eliminated the wlan0 gateway (DHCPCD.conf has added line “interface wlan0”, “nogateway”).

I’ve set the metric for wwan0 to 100 (“interface wwan0”, metric 100”)

Route -n confirms this.

Using the wlan0 IP, http://192.168.1.238:5000/hello returns a “Hello” as it should.

Using the wwan0 IP, http://192.168.225.37:5000/hello returns “failed to open page, server not responding”.

I’m not a network guru, so I’ve probably overlooked something simple. Any ideas?

The fact that the server software work for wlan0 says that’s not it. The ability to ping says the hardware is installed ok.

Any suggestions are most welcome!!

Chuck

Hello @cbenton ,

Let me know if I got it right.
You are able to access the web server when your laptop and Raspberry Pi are on the same network.
Let’s say if your laptop is connected to a different Wifi(network) are you still able to access your web server?

You can use 3rd party solution such as remote.it for HTTPS.