File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 77 < base href ="/ ">
88 < meta charset ="UTF-8 ">
99 < meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
10+ <!-- Aspire: point browser OTLP exporter to API proxy to avoid CORS -->
11+ < meta name ="otlp-endpoint " content ="http://localhost:5179/otlp/v1/traces ">
1012 <!-- Local Conduit CSS to avoid CORS errors -->
1113 < link rel ="stylesheet " href ="css/main.css " />
1214 < link href ="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css " rel ="stylesheet " type ="text/css " crossorigin ="anonymous ">
Original file line number Diff line number Diff line change @@ -35,6 +35,12 @@ void (async () => {
3535 const guessOtlp = ( ) => {
3636 // Allow explicit global override
3737 if ( window . __OTLP_ENDPOINT ) return window . __OTLP_ENDPOINT ;
38+ // Allow per-app meta override: <meta name="otlp-endpoint" content="https://collector:4318/v1/traces">
39+ try {
40+ const meta = document . querySelector ( 'meta[name="otlp-endpoint"]' ) ;
41+ const v = meta && meta . getAttribute ( 'content' ) ;
42+ if ( v ) return v ;
43+ } catch { }
3844 // Prefer a same-origin proxy to avoid CORS issues with collectors
3945 try { return new URL ( '/otlp/v1/traces' , window . location . origin ) . href ; } catch { }
4046 // Fallback to common local collector endpoints
You can’t perform that action at this time.
0 commit comments