WebUI Vue
The Vue-based WebUI lives in webui-vue/. It was introduced as a
technical preview in Bareos 25.1 and is the default WebUI in Bareos 26.
The classic PHP-based WebUI in webui/ remains available in parallel.
Coexistence model
The repository currently contains two different WebUI implementations:
webui/for the classic PHP-based WebUIwebui-vue/for the Vue-based WebUI
Documentation, packaging, and operational guidance should reflect that both variants currently coexist. Changes to the Vue WebUI should not implicitly assume that it has already replaced the classic WebUI everywhere.
Repository layout
The most relevant parts of the Vue WebUI are:
webui-vue/src/for the application sourcewebui-vue/src/pages/for page-level route componentswebui-vue/src/components/for reusable UI componentswebui-vue/src/composables/for shared page and data-loading logicwebui-vue/src/stores/for Pinia storeswebui-vue/src/generated/for generated version and translation datawebui-vue/tests/unit/for unit testswebui-vue/tests/e2e/for Playwright-based end-to-end tests
Build and installation
The installable SPA bundle is generated from the repository root with:
cmake --build <builddir> --target bareos-webui-vue-build
The build logic is implemented in:
webui-vue/CMakeLists.txtwebui-vue/build-dist.cmake
The Vue package is bareos-webui-vue, which provides
bareos-webui. The PHP package is bareos-webui-php.
The installed Apache configuration is generated from:
webui-vue/install/apache/bareos-webui-vue.conf.in
The SPA is installed below
$CMAKE_INSTALL_FULL_DATAROOTDIR/bareos-webui-vue
(normally /usr/share/bareos-webui-vue/) and exposed at /bareos/.
The root URL and the former /bareos-webui-new/ technical-preview URL
redirect to /bareos/; the PHP URL remains /bareos-webui.
Runtime architecture
Unlike the classic PHP WebUI, the Vue WebUI does not talk to the Director through PHP. Instead it uses bareos-webui-proxy for both HTTP session handling and WebSocket-based director communication.
The default Apache configuration:
serves the SPA from
/bareos/rewrites SPA routes back to
index.htmlproxies
/bareos/wsto bareos-webui-proxy on port 9104proxies
/bareos/api/to bareos-webui-proxy on port 9104
Apache removes the /bareos prefix when forwarding to the proxy.
The browser calls GET /bareos/api/session,
POST /bareos/api/session/directors/<director>/login, and
DELETE /bareos/api/session.
The proxy receives GET /api/session,
POST /api/session/directors/<director>/login, and
DELETE /api/session.
The WebSocket side is then used for the live director connection once the
session has been established.
The proxy configuration behavior is:
without
--config, it first tries/etc/bareos-webui-proxy/bareos-webui-proxy.iniif that file is missing, it uses built-in defaults
with explicit
--config, the specified file is required
Any existing configuration file must satisfy Configuration file access rights, regardless of whether it enables PAM. The loader checks the opened file and immediate containing directory before parsing. Unsafe access rights cause startup failure with an actionable diagnostic.
The default configuration template is installed as
bareos-webui-proxy.ini in $configtemplatedir.
PAM login
The existing Vue login form and API both accept only the user’s username and
password. For a PAM-enabled Director target, configure pam_console_name and
pam_console_password in that target’s proxy INI section. The proxy uses
these server-side credentials for TLS-PSK and CRAM-MD5 Console authentication.
It interprets the submitted username/password as the PAM user’s credentials:
{
"username": "<pam-user>",
"password": "<pam-password>"
}
Post this payload to /api/session/directors/selector/login.
The Director’s Console must have UsePamAuthentication = yes; login fails
if it does not request PAM, rather than granting the Console’s own access.
A matching Director User resource determines the authenticated user’s access.
Login requests must contain exactly the two string fields shown above;
duplicate or additional fields are rejected. PAM usernames and passwords must
be nonempty and contain no NUL or record-separator characters.
Malformed requests return HTTP 400 and authentication failures return HTTP 401.
This implements bconsole’s direct-credentials mode, not interactive PAM
prompts. Configuring PAM with tls_psk_disable = yes is a startup error.
Targets without the PAM Console settings retain ordinary Console login.
Protect browser/API traffic with HTTPS as well; Director TLS protects only
the proxy-to-Director connection.
After successful login, use the session cookie for subsequent requests.
WebSocket sessions use {"type":"session","director":"<selector>","mode":"raw"}
for a text console, or "mode":"json" for JSON commands.
The proxy retains the user’s credentials in server-side session memory for
reconnects and explicit credential reuse. Each Director connection uses that
target’s configured Console credentials, including when reusing the same user
credentials across Directors. Shared Console credentials remain in the
restricted server-side INI file, not browser requests or session records.
Session expiry, logout, or removing a Director removes its stored user
credentials. Session responses identify the user but never expose passwords
or the shared Console credentials. See Bareos WebUI Vue for setup.
Testing
Typical local validation commands are:
cd webui-vue && npm run build
cd webui-vue && npm run test:unit
ctest --test-dir cmake-build --parallel "$(nproc)" --output-on-failure -R '^webui-vue:'
The browser-based system tests use the shared WebUI Vue test setup under:
systemtests/tests/webui-vue-common/
Translations
The Vue WebUI currently reuses the legacy WebUI locale sources and generated catalog data.
Relevant files are:
webui-vue/scripts/generate-webui-i18n.mjswebui-vue/src/generated/webui-locales.jswebui-vue/src/generated/webui-messages.jswebui/module/Application/language/
To regenerate the committed Vue translation catalog files, run:
cd webui-vue && npm run generate:i18n
Documentation guidance
When documenting Vue WebUI work:
add operator-facing documentation to the introduction/tutorial manual
add implementation and workflow details here in the developer guide
distinguish the Bareos 25.1 technical preview from the default Vue WebUI in Bareos 26
avoid wording that implies the classic WebUI no longer exists unless that product decision has changed