Website sidebar now mirrors the App Center (sidebar.css): a 220px full-height column, full-width category rows with bottom-border separators and the real per-category icons (bundled into the site by the install hook from the live frontend), and the same search box — instead of the rounded pills + generic circles + count badges it had. Marketplace app copy shortened to peer style: description 'App Catalog & Registry', one-sentence long description. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Signed-off-by: librelad <librelad@digitalangels.vip>
35 lines
1.6 KiB
Bash
35 lines
1.6 KiB
Bash
#!/bin/bash
|
|
|
|
# Marketplace install hooks — seed the served docroot. The generic installApp
|
|
# driver handles compose/start; this converges the browse-UI files on every
|
|
# (re)install (always refreshed from the definition), while published channel
|
|
# data (stable/, edge/ — the operator's signed catalog) is never touched.
|
|
|
|
marketplace_install_post_setup()
|
|
{
|
|
local app_name="$1"
|
|
local def="${install_containers_dir%/}/$app_name"
|
|
local live="$containers_dir$app_name"
|
|
local dest="$live/data"
|
|
|
|
# The compose bind-mounts nginx.conf as a FILE; the generic installer
|
|
# copies only config+compose, and a premature container start leaves a
|
|
# directory placeholder at the mount path — converge both cases.
|
|
[[ -d "$live/nginx.conf" ]] && runFileOp rm -rf "$live/nginx.conf"
|
|
runFileOp cp -f "$def/nginx.conf" "$live/nginx.conf" || return 1
|
|
|
|
runFileOp mkdir -p "$dest" || return 1
|
|
runFileOp cp -f "$def/resources/site/index.html" "$dest/index.html" || return 1
|
|
runFileOp cp -f "$def/$app_name.svg" "$dest/marketplace.svg" || return 1
|
|
|
|
# Bundle the App Center's category icons so the site's sidebar matches the
|
|
# WebUI (same per-category glyphs). Copied from the live frontend so they
|
|
# stay in step; best-effort (the site falls back to misc.svg if absent).
|
|
local cat_src="$containers_dir/libreportal/frontend/core/icons/categories"
|
|
if [[ -d "$cat_src" ]]; then
|
|
runFileOp mkdir -p "$dest/categories" || true
|
|
runFileOp cp -f "$cat_src"/*.svg "$dest/categories/" 2>/dev/null || true
|
|
fi
|
|
isSuccessful "Marketplace site seeded. Publish a catalog into it: rsync dist/<channel>/ $dest/<channel>/"
|
|
}
|