Firebase Emulator never fires up

Viewed 664

I have the following versions npm - 8.1.0 java - openjdk 11.0.13 2021-10-19 LTS

I'm on a M1 Mac.

I have selected only the firestore emulator to run, successfully logged in, etc.

I do firebase emulators:start

Here is my output

i  emulators: Starting emulators: firestore
i  firestore: Firestore Emulator logging to firestore-debug.log

it then hangs here for 60 seconds and then I get this

i  emulators: Shutting down emulators.
i  firestore: Stopping Firestore Emulator
i  hub: Stopping emulator hub

Error: TIMEOUT: Port 8085 on localhost was not active within 60000ms

Note that I have tried 8080, the default and also 8085 just to try a different port but same behavior.

Firestore debug look like this

Dec 10, 2021 10:38:11 AM com.google.cloud.datastore.emulator.firestore.websocket.WebSocketServer start
INFO: Started WebSocket server on ws://localhost:49860
API endpoint: http://localhost:8085
If you are using a library that supports the FIRESTORE_EMULATOR_HOST environment variable, run:

   export FIRESTORE_EMULATOR_HOST=localhost:8085

Dev App Server is now running.

*** shutting down gRPC server since JVM is shutting down
*** server shut down

Any ideas on what might be wrong or how I can resolve?

1 Answers

I was using node v17. Using nvm I reverted to node v14.16.0 and it started up properly

Also I found that enter this command is critical for the firestore UI to show entries made by my iOS app.

export FIRESTORE_EMULATOR_HOST=localhost:8080

Related