🔧 fix: update Traefik router rule for MCP/curl access to include host condition
✨ feat: enable sending default PII in Sentry initialization
This commit is contained in:
@@ -20,8 +20,8 @@ services:
|
||||
- traefik.enable=true
|
||||
- online.testversion.code.subdomain=${PROJECT_NAME}
|
||||
# Create two routers: one without auth for MCP/curl, one with auth for others
|
||||
# Router 1: MCP/curl access (based on user-agent header)
|
||||
- traefik.http.routers.${PROJECT_NAME}-yarnstart-mcp.rule=HeadersRegexp(`User-Agent`, `.*(Playwright|puppeteer|Headless|curl).*`)
|
||||
# Router 1: MCP/curl access (based on host + user-agent header)
|
||||
- traefik.http.routers.${PROJECT_NAME}-yarnstart-mcp.rule=Host(`${PROJECT_NAME}.code.testversion.online`) && HeadersRegexp(`User-Agent`, `.*(Playwright|puppeteer|Headless|curl).*`)
|
||||
- traefik.http.routers.${PROJECT_NAME}-yarnstart-mcp.priority=100
|
||||
- traefik.http.routers.${PROJECT_NAME}-yarnstart-mcp.service=${PROJECT_NAME}-yarnstart
|
||||
# Router 2: Regular access with basic auth
|
||||
|
||||
@@ -25,6 +25,7 @@ export const init = (dsn: string, tracingOrigins: (string | RegExp)[], environme
|
||||
release: release,
|
||||
replaysSessionSampleRate: 1.0,
|
||||
replaysOnErrorSampleRate: 1.0,
|
||||
sendDefaultPii: true,
|
||||
})
|
||||
console.log("Sentry initialized")
|
||||
initialized = true
|
||||
|
||||
Reference in New Issue
Block a user