diff --git a/birdnet-pipy/CHANGELOG.md b/birdnet-pipy/CHANGELOG.md index 61400f05b..fc629fcbc 100644 --- a/birdnet-pipy/CHANGELOG.md +++ b/birdnet-pipy/CHANGELOG.md @@ -1,3 +1,8 @@ +## 0.6.3 (2026-04-13) +- Simplify ingress nginx to a single `` rewrite. Upstream now declares `` in `index.html` with Vite `base: './'` and uses relative paths for all internal URLs (built assets, axios `baseURL`, socket.io `path`). The previous seven `sub_filter` rules (href/src/`/api`/`/socket.io`) are no longer needed — one `` replacement is sufficient. +- Removes incidental brittleness from byte-level `sub_filter` matches in minified JS bundles (the old `/stream/` rule had inadvertently double-prefixed the literal `api.get("/stream/config")` string). +- Update to latest version from Suncuss/BirdNET-PiPy (changelog : https://github.com/Suncuss/BirdNET-PiPy/releases) + ## 0.6.2-2 (11-04-2026) - Minor bugs fixed diff --git a/birdnet-pipy/config.yaml b/birdnet-pipy/config.yaml index 0eb84ba83..26c05a2da 100644 --- a/birdnet-pipy/config.yaml +++ b/birdnet-pipy/config.yaml @@ -97,4 +97,4 @@ schema: ssl: bool? slug: birdnet-pipy url: https://github.com/alexbelgium/hassio-addons/tree/master/birdnet-pipy -version: "0.6.2-2" +version: "0.6.3" diff --git a/birdnet-pipy/rootfs/etc/nginx/includes/ingress_params.conf b/birdnet-pipy/rootfs/etc/nginx/includes/ingress_params.conf index dd72c0fa0..326eb3c15 100644 --- a/birdnet-pipy/rootfs/etc/nginx/includes/ingress_params.conf +++ b/birdnet-pipy/rootfs/etc/nginx/includes/ingress_params.conf @@ -1,26 +1,12 @@ absolute_redirect off; rewrite ^%%ingress_entry%%/(.*)$ /$1 break; -sub_filter_once off; -sub_filter_types *; +sub_filter_once on; +sub_filter_types text/html; -# Inject for Vue Router history mode and static asset loading -sub_filter '' ''; - -# Rewrite absolute href/src attributes in HTML -sub_filter 'href="/' 'href="%%ingress_entry%%/'; -sub_filter 'src="/' 'src="%%ingress_entry%%/'; - -# Rewrite API paths in JS bundles (axios baseURL and fetch calls) -# Pattern includes baseURL:"/api" (no trailing slash) so "/api" is needed -sub_filter '"/api' '"%%ingress_entry%%/api'; -sub_filter "'/api" "'%%ingress_entry%%/api"; - -# Do NOT rewrite "/stream/" — LiveFeed.vue strips the leading slash from -# stream URLs returned by /api/stream/config so they resolve relative to -# (injected above). Adding a sub_filter -# for '/stream/' would also rewrite the literal 'api.get("/stream/config")' -# inside the JS bundle, producing a double-prefixed request. - -# Rewrite Socket.IO default path in the client library -sub_filter '"/socket.io' '"%%ingress_entry%%/socket.io'; -sub_filter "'/socket.io" "'%%ingress_entry%%/socket.io"; +# Rewrite the frontend's default to the ingress prefix so +# all relative URLs (assets, axios baseURL, socket.io path) resolve under +# ingress. The frontend declares BASE once via this tag; no other rewrites +# are needed. Pattern deliberately omits the closing bracket so it matches +# both self-closing () and non-self-closing () +# forms. sub_filter_once above ensures only the first occurrence is touched. +sub_filter '