-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fastify server: Default to localhost #8019
Fastify server: Default to localhost #8019
Conversation
Maybe related: #6362 |
Merging this in alignment with discussions over at #8233 (comment) |
* Fastify server: Default to localhost * explicitly set host to localhost --------- Co-authored-by: Josh GM Walker <[email protected]>
…te-default * 'main' of github.com:redwoodjs/redwood: (23 commits) fix: remove react 17/18 warning (redwoodjs#8300) chore(release): tolerate lerna publish faliure Recover lost connection (redwoodjs#8284) chore(deps): update dependency @faker-js/faker to v8 (redwoodjs#8296) chore(release): better git commits during release feat: experimental - Studio Overview and Performance Widgets (redwoodjs#8292) fix(forms): disable webpack-dev-server overlay (redwoodjs#8298) Fix studio lint warning (redwoodjs#8297) Fastify server: Default to localhost (redwoodjs#8019) Fix GraphQL proxy in dev environments without IPv6 (redwoodjs#8233) fix(deps): update dependency @graphiql/plugin-explorer to v0.1.18 (redwoodjs#8290) chore(deps): update dependency supertokens-auth-react to v0.32.3 (redwoodjs#8289) Add `setup sentry` command (redwoodjs#7790) chore: readme update core team and all contributors (redwoodjs#8288) fix(deps): update nivo monorepo to ^0.83.0 (redwoodjs#8286) fix(deps): update dependency babel-plugin-polyfill-corejs3 to v0.8.1 (redwoodjs#8281) chore(deps): update dependency @replayio/playwright to v0.3.30 (redwoodjs#8282) fix(deps): update dependency webpack to v5.82.1 (redwoodjs#8283) Add epilogue to builders (redwoodjs#8285) feat(studio): v2 studio (redwoodjs#8173) ...
The fastify link above states some exceptions, when Not to use localhost.
|
Also sorry @Tobbe we appear to have went backwards on this work when we added the fastify ejection and updated the CLI handlers to use the new fastify package:
|
After upgrade to 5.2.3, run yarn rw dev, and the Erroe: |
@steveoon Can you please post your full console output? And the output of |
@steveoon we reverted this change in [v5.2.3])https://github.com/redwoodjs/redwood/releases/tag/v5.2.3). There was a span of time between v5.2.0 and v5.2.3 (a few days really) where this functionality was in a stable release—did you make a change to api or web hosts in that span in |
The table here is good for understanding the
host
options https://www.fastify.io/docs/latest/Reference/Server/#listenI chose to just remove the option, which will use the default, which is(See EDIT below)localhost
. If someone prefers to be more explicit about it, let me know and I'll add it in.I needed this change for #8002
It will also work towards making it possible to use RW in ipv6-only environments (at least it should help, more changes might be needed in other places)
EDIT:
I decided to keep the
host
config, but changed it tolocalhost
, which is the default. Right now this is a bit redundant, but at some point we'll want to make this configurable (see #6362) and then we'll need it.