mirror of
https://github.com/eduardolat/pgbackweb.git
synced 2026-04-25 05:35:57 +03:00
[PR #139] [MERGED] Adds support for path prefix configuration #160
Labels
No labels
bug
confirmed next step
duplicate
enhancement
help wanted
in progress
in progress
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/pgbackweb#160
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/eduardolat/pgbackweb/pull/139
Author: @PatrikScully
Created: 10/3/2025
Status: ✅ Merged
Merged: 10/5/2025
Merged by: @eduardolat
Base:
develop← Head:feature/path-prefix📝 Commits (6)
2e0447dAdds support for path prefix configuratione91d202Refactors pathutil test suite for better isolation6965e14Supports subdirectory deployment with configurable path prefix7658e21Refactors URL paths using pathutil.BuildPath function7b81f8aStandardizes URL path formatting in dashboard componentsf39598dRefactors URL handling with pathutil.BuildPath📊 Changes
54 files changed (+473 additions, -92 deletions)
View changed files
📝
README.md(+5 -0)📝
cmd/app/main.go(+5 -1)📝
internal/config/env.go(+1 -0)📝
internal/config/env_validate.go(+4 -0)➕
internal/util/pathutil/pathutil.go(+35 -0)➕
internal/util/pathutil/pathutil_test.go(+87 -0)➕
internal/validate/path_prefix.go(+43 -0)➕
internal/validate/path_prefix_test.go(+78 -0)📝
internal/view/middleware/require_auth.go(+7 -4)📝
internal/view/middleware/require_no_auth.go(+4 -2)📝
internal/view/router.go(+18 -4)📝
internal/view/static/static_fs.go(+9 -1)📝
internal/view/web/auth/create_first_user.go(+4 -3)📝
internal/view/web/auth/login.go(+4 -3)📝
internal/view/web/auth/logout.go(+3 -2)📝
internal/view/web/component/logotype.go(+2 -1)📝
internal/view/web/component/support_project.inc.js(+43 -2)📝
internal/view/web/dashboard/backups/create_backup.go(+4 -3)📝
internal/view/web/dashboard/backups/delete_backup.go(+4 -1)📝
internal/view/web/dashboard/backups/duplicate_backup.go(+4 -1)...and 34 more files
📄 Description
Introduces configurable path prefix to serve application under subpath (e.g., /pgbackweb) Implements validation for path prefixes in environment variables Updates all redirects and routes to use the configured path prefix
This allows deploying the app at a custom URL path while maintaining correct functionality.
Summary by CodeRabbit
New Features
Documentation
Tests
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.