umami-software / umami

Umami is a simple, fast, privacy-focused alternative to Google Analytics.
https://umami.is
MIT License
23.06k stars 4.29k forks source link

CORS with custom API endpoint #3022

Open romangg opened 1 month ago

romangg commented 1 month ago

Describe the Bug

I'm running latest Umami Docker container behind Traefik. Website to track runs Nuxt with Umami module. When using a custom API endpoint like /api/getdata instead of /api/send I'm getting CORS violations.

Making exceptions for CORS via Traefik similar to here, removes the error. But then I get 405 - Method not allowed.

Only the default endpoint /api/send works for me without issues.

Database

PostgreSQL

Relevant log output

No response

Which Umami version are you using? (if relevant)

No response

Which browser are you using? (if relevant)

No response

How are you deploying your application? (if relevant)

Docker

mikecao commented 1 month ago

Are you able to run it without Traefik?