Initial commit
This commit is contained in:
17
docs/troubleshoot.md
Normal file
17
docs/troubleshoot.md
Normal file
@@ -0,0 +1,17 @@
|
||||
# Troubleshooting docs
|
||||
|
||||
## "message":"Websocket upgrade failed: websocket: request origin not allowed by Upgrader.CheckOrigin"
|
||||
|
||||
If you deploy your Rango somewhere, lets say to _www.rango.host_, and try to connect with some local
|
||||
frontend app you develop, you'll probably face this problem.
|
||||
|
||||
It is caused by [CORS](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS), to resolve this issue
|
||||
specify a list of domains, allowed to connect to server in Rango `API_CORS_ORIGINS` env var.
|
||||
|
||||
By default, if this env is not set, only requests from _www.rango.host_ are enabled.
|
||||
|
||||
So, if I have some react-app running on _localhost:3000_:
|
||||
|
||||
```
|
||||
API_CORS_ORIGINS=www.rango.host,localhost:3000
|
||||
```
|
||||
Reference in New Issue
Block a user