I was having this having this problem with using firebase serve
on MacBook Pro (14-inch, 2021), Apple M1 Pro, macOS Monterey 12.3
UPDATE:
so apparently the reason was
macOS Monterey introduced AirPlay Receiver running on port 5000. This prevents your web server from serving on port 5000. Receiver already has the port.
so the solution proposed by the answer quoted above, was to either turn off the AirPlay Receiver, or to run your app on another port.
if you are running your app using firebase serve, You can change the port by following this approach:
source
firebase.json file doesn't work with the the firebase serve command.
You have to use the firebase emulators:start command.
If you want to keep using firebase serve then it should be use like
in:
firebase serve --only hosting --port=5002
OLD ANSWER:
Not a sufficient answer, but I was able to bypass this by entering 127.0.0.1
instead of localhost
. I don't think this is the best answer, neither I am satisfied with it. I'll definitely come back later and update the answer once I find a better answer.