Skip to content

Commit

Permalink
Merge pull request #3810 from mikiher/enable-subdirectory
Browse files Browse the repository at this point in the history
Enable subdirectory support by default
  • Loading branch information
advplyr authored Jan 19, 2025
2 parents 4a3254d + 9668b49 commit 58ca264
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion client/nuxt.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const pkg = require('./package.json')

const routerBasePath = process.env.ROUTER_BASE_PATH || ''
const routerBasePath = process.env.ROUTER_BASE_PATH || '/audiobookshelf'
const serverHostUrl = process.env.NODE_ENV === 'production' ? '' : 'http://localhost:3333'
const serverPaths = ['api/', 'public/', 'hls/', 'auth/', 'feed/', 'status', 'login', 'logout', 'init']
const proxy = Object.fromEntries(serverPaths.map((path) => [`${routerBasePath}/${path}`, { target: process.env.NODE_ENV !== 'production' ? serverHostUrl : '/' }]))
Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const CONFIG_PATH = inputConfig || process.env.CONFIG_PATH || Path.resolve('conf
const METADATA_PATH = inputMetadata || process.env.METADATA_PATH || Path.resolve('metadata')
const SOURCE = options.source || process.env.SOURCE || 'debian'

const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || ''
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || '/audiobookshelf'

console.log(`Running in ${process.env.NODE_ENV} mode.`)
console.log(`Options: CONFIG_PATH=${CONFIG_PATH}, METADATA_PATH=${METADATA_PATH}, PORT=${PORT}, HOST=${HOST}, SOURCE=${SOURCE}, ROUTER_BASE_PATH=${ROUTER_BASE_PATH}`)
Expand Down
2 changes: 1 addition & 1 deletion prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const CONFIG_PATH = inputConfig || process.env.CONFIG_PATH || Path.resolve('conf
const METADATA_PATH = inputMetadata || process.env.METADATA_PATH || Path.resolve('metadata')
const SOURCE = options.source || process.env.SOURCE || 'debian'

const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || ''
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || '/audiobookshelf'

console.log(process.env.NODE_ENV, 'Config', CONFIG_PATH, METADATA_PATH)

Expand Down

0 comments on commit 58ca264

Please sign in to comment.