[PR #3530] [MERGED] Add server proxies for all server paths #4006

Closed
opened 2026-04-25 00:17:56 +02:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/advplyr/audiobookshelf/pull/3530
Author: @mikiher
Created: 10/17/2024
Status: Merged
Merged: 10/17/2024
Merged by: @advplyr

Base: masterHead: subdirectory-fixes-2


📝 Commits (1)

  • 49ed208 Add dev proxies for all server path

📊 Changes

2 files changed (+3 additions, -7 deletions)

View changed files

📝 client/nuxt.config.js (+3 -6)
📝 client/plugins/axios.js (+0 -1)

📄 Description

Your recent Add in /dev proxy for development is incomplete since it doesn't take care of all url references. Since the `/dev' prefix is added only for axios calls, it doesn't cover references to the server that are not through axios calls.

For this to work properly without having to modify individual references in the client code, we need to proxy all routes that need to go to the server.

Unfortunately there's no top-level namespace (like /server) that identifies server paths from client paths, so we just need to specify all server paths that are referenced by the client individually.

This is what's implemented in this PR.

  • /login, /logout, /status, and /init now work properly.
  • Also added proxies for /feed/ and /auth/ which probably also did not work properly before.
  • There are no references to /ping or healthcheck so I left them out of the list
  • Made the proxy definition more compact

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/advplyr/audiobookshelf/pull/3530 **Author:** [@mikiher](https://github.com/mikiher) **Created:** 10/17/2024 **Status:** ✅ Merged **Merged:** 10/17/2024 **Merged by:** [@advplyr](https://github.com/advplyr) **Base:** `master` ← **Head:** `subdirectory-fixes-2` --- ### 📝 Commits (1) - [`49ed208`](https://github.com/advplyr/audiobookshelf/commit/49ed208a548b506a1315b9a84059b7668081d517) Add dev proxies for all server path ### 📊 Changes **2 files changed** (+3 additions, -7 deletions) <details> <summary>View changed files</summary> 📝 `client/nuxt.config.js` (+3 -6) 📝 `client/plugins/axios.js` (+0 -1) </details> ### 📄 Description Your recent [Add in /dev proxy for development](https://github.com/advplyr/audiobookshelf/commit/9d1f51c6ba0201f42e72f56a3b25e539a19a8c66) is incomplete since it doesn't take care of all url references. Since the `/dev' prefix is added only for axios calls, it doesn't cover references to the server that are not through axios calls. For this to work properly without having to modify individual references in the client code, we need to proxy all routes that need to go to the server. Unfortunately there's no top-level namespace (like `/server`) that identifies server paths from client paths, so we just need to specify all server paths that are referenced by the client individually. This is what's implemented in this PR. - `/login`, `/logout`, `/status`, and `/init` now work properly. - Also added proxies for `/feed/` and `/auth/` which probably also did not work properly before. - There are no references to `/ping` or `healthcheck` so I left them out of the list - Made the proxy definition more compact --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2026-04-25 00:17:56 +02:00
adam closed this issue 2026-04-25 00:17:56 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf#4006