My app has a Flask backend and an Angular/Electron frontend. The app runs locally on Mac Catalina. Flask, Celery and Redis are in separate docker containers, while the frontend
A working solution is based on the David Maze and Matt's comments and on this question. These are the steps:
"ip": "127.0.0.1"
to the json config file.ports
to "127.0.0.1:5078:5078"
for the web
service.0.0.0.0
As I checked, messages from Electron's localhost 4201 went through. Also, running netstat -anvp tcp | awk 'NR<3 || /LISTEN/
shows that the insecure port 0.0.0.0.5078
is no longer exposed to the outside.
`