This document describes how PROXMUX Manager integrates Community Scripts metadata and install command generation.
The extension uses a provider boundary with a GitHub-backed default source:
- Primary source: GitHub repository tree API
https://api.github.com/repos/community-scripts/ProxmoxVE/git/trees/main?recursive=1
- Normalization layer
- Maps file paths into a stable script record (
slug,type,name,description,installUrl,scriptPath).
- Maps file paths into a stable script record (
- Cache fallback
- If GitHub is temporarily unavailable, stale cache is returned with
source=cache-fallback.
- If GitHub is temporarily unavailable, stale cache is returned with
This strategy is implemented in lib/community-scripts.js.
Catalog entries are normalized to:
nameslugtypedescriptioninstallUrl(trusted raw GitHub URL)scriptPath(repo-relative source path)
The popup consumes this normalized model directly and lazily reads details from the same provider boundary (getCommunityScriptDetails).
Data is cached in chrome.storage.local:
communityScriptsCatalogCacheV1communityScriptsDetailsCacheV1
Catalog cache stores metadata (source, updatedAt, schemaVersion) and script records.
The cache TTL is configurable in Options (communityScriptsCacheTtlHours). If a fresh GitHub fetch fails, stale cached data is served with warning state for UI messaging.
Command generation is implemented in lib/install-command.js.
- Only trusted raw GitHub URLs are accepted:
https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/...
- A command block is built per selected script:
# Script Name
bash -c '$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/example.sh)'Execution is intentionally assisted, not fully automatic:
- User selects one or more scripts in popup.
- Extension builds and copies install commands to clipboard.
- Extension opens or focuses a Proxmox node shell tab.
- Extension attempts to auto-paste the command into the shell input (without pressing Enter).
- User reviews and executes manually.
No remote auto-execution is performed by default.
- Slug names can differ from desired display naming; deterministic rules are used and an explicit override map exists for exceptional paths.
- GitHub API rate limiting may apply for very frequent refreshes.
Provider calls already go through:
getCommunityScriptsCatalog(options)getCommunityScriptDetails(slug, options)
To move to an external scraper/DB pipeline later:
- Add a DB-backed provider implementing the same normalized record contract.
- Route source selection in
community-scripts.jsbehind a small provider switch (GitHub vs DB). - Keep popup/UI unchanged because it only consumes normalized records and source status.
Main integration is in:
popup/popup.htmlpopup/popup.jspopup/popup.css
Related settings are in:
options/options.htmloptions/options.js