Add Traefik CORS Example

Testing and working with Traefik v2.11.0.
This commit is contained in:
arcoast
2024-04-01 21:32:46 +01:00
committed by GitHub
parent 34d170ccea
commit 58741ef224
+24
View File
@@ -88,6 +88,30 @@ server {
}
```
### Traefik example
Add this middleware to your Invidious instance:
```yaml
http:
middlewares:
materialious:
headers:
accessControlAllowCredentials: true
accessControlAllowOrigin: "https://materialious.example.com"
accessControlAllowMethods:
- GET
- POST
- OPTIONS
- HEAD
- PATCH
- PUT
- DELETE
accessControlAllowHeaders:
- User-Agent
- Authorization
- Content-Type
```
### Other
Please open a PR request or issue if you implement this in a different reverse proxy.