You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+9-1Lines changed: 9 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ This [`fastify`](https://www.fastify.io) plugin forwards all requests
9
9
received with a given prefix (or none) to an upstream. All Fastify hooks are still applied.
10
10
11
11
`@fastify/http-proxy` is built on top of
12
-
[`@fastify/reply-from`](http://npm.im/fastify-reply-from), which enables single route proxying.
12
+
[`@fastify/reply-from`](https://npm.im/@fastify/reply-from), which enables single route proxying.
13
13
14
14
This plugin can be used in a variety of circumstances, for example if you have to proxy an internal domain to an external domain (useful to avoid CORS problems) or to implement your own API gateway for a microservices architecture.
15
15
@@ -187,6 +187,14 @@ A few things are missing:
187
187
188
188
Pull requests are welcome to finish this feature.
189
189
190
+
### `wsUpstream`
191
+
Working only if property `websocket` is `true`.
192
+
193
+
An URL (including protocol) that represents the target websockets to use for proxying websockets.
194
+
Accepted both `https://` and `wss://`.
195
+
196
+
Note that if property `wsUpstream` not specified then proxy will try to connect with the `upstream` property.
197
+
190
198
### `wsServerOptions`
191
199
192
200
The options passed to [`new ws.Server()`](https://github.com/websockets/ws/blob/HEAD/doc/ws.md#class-websocketserver).
0 commit comments