Skip to content

Use shell:true for Pub/Sub emulator on Windows - #7033

Merged
joehan merged 3 commits into
masterfrom
jh-windows-pubsub-fix
Apr 23, 2024
Merged

Use shell:true for Pub/Sub emulator on Windows#7033
joehan merged 3 commits into
masterfrom
jh-windows-pubsub-fix

Conversation

@joehan

@joehan joehan commented Apr 22, 2024

Copy link
Copy Markdown
Member

Description

Fixes #7026.

nodejs/node#52554 Release Blog Post causes spawn/spawnSync to error out when executing bat/cmd files directly without the shell:true option.

@joehan
joehan requested a review from aalej April 22, 2024 17:50
Comment thread src/emulator/downloadableEmulators.ts Outdated
@joehan
joehan requested a review from aalej April 22, 2024 21:33

@aalej aalej left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Verified the fix on a Windows machine with Node.js v18.20.2

C:\Users\<PATH>\issues-7026>node -v
v18.20.2

C:\Users\ <PATH>\issues-7026>firebase emulators:start
i  emulators: Starting emulators: functions, pubsub
!  functions: The following emulators are not running, calls to these services from the Functions emulator will affect production: auth, firestore, database, hosting, storage
i  pubsub: Pub/Sub Emulator logging to pubsub-debug.log
i  ui: Emulator UI logging to ui-debug.log
i  functions: Watching "C:\Users\<PATH>\issues-7026\functions" for Cloud Functions...
+  functions: Using node@18 from host.
Serving at port 8582

+  functions: Loaded functions definitions from source: .

┌─────────────────────────────────────────────────────────────┐
│ ✔  All emulators ready! It is now safe to connect your app. │
│ i  View Emulator UI at http://127.0.0.1:4000/               │
└─────────────────────────────────────────────────────────────┘

┌───────────┬────────────────┬─────────────────────────────────┐
│ Emulator  │ Host:Port      │ View in Emulator UI             │
├───────────┼────────────────┼─────────────────────────────────┤
│ Functions │ [127.0.0.1:5001](http://127.0.0.1:5001/) │ http://127.0.0.1:4000/functions │
├───────────┼────────────────┼─────────────────────────────────┤
│ Pub/Sub   │ [127.0.0.1:8085](http://127.0.0.1:8085/) │ n/a                             │
└───────────┴────────────────┴─────────────────────────────────┘
  Emulator Hub running at [127.0.0.1:4400](http://127.0.0.1:4400/)
  Other reserved ports: 4500

Issues? Report them at https://github.com/firebase/firebase-tools/issues and attach the *-debug.log files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Regression from node 18 CVE-2024-27980

2 participants