This commit is contained in:
Dorian
2026-03-15 00:40:55 +00:00
parent bf34060f9d
commit bd40fac0e6
16 changed files with 1886 additions and 398 deletions
+1 -68
View File
@@ -639,75 +639,8 @@ function isInstalled(appId: string): boolean {
return aliases ? aliases.some((a) => a in installedPackages.value) : false
}
/** Web-only apps — external URLs with no container */
const WEB_ONLY_APP_URLS: Record<string, string> = {
'botfights': 'https://botfights.net',
'nwnn': 'https://nwnn.l484.com',
'484-kitchen': 'https://484.kitchen',
'call-the-operator': 'https://cta.tx1138.com',
'arch-presentation': 'https://present.l484.com',
'syntropy-institute': 'https://syntropy.institute',
't-zero': 'https://teeminuszero.net',
'nostrudel': 'https://nostrudel.ninja',
}
/** App ID to port-based URL for container apps */
const APP_LAUNCH_URLS: Record<string, string> = {
'bitcoin-knots': 'http://localhost:8334',
'btcpay-server': 'http://localhost:23000',
'lnd': 'http://localhost:8081',
'mempool': 'http://localhost:4080',
'homeassistant': 'http://localhost:8123',
'grafana': 'http://localhost:3000',
'searxng': 'http://localhost:8888',
'ollama': 'http://localhost:11434',
'onlyoffice': 'http://localhost:9980',
'penpot': 'http://localhost:9001',
'nextcloud': 'http://localhost:8085',
'vaultwarden': 'http://localhost:8082',
'jellyfin': 'http://localhost:8096',
'photoprism': 'http://localhost:2342',
'immich': 'http://localhost:2283',
'filebrowser': 'http://localhost:8083',
'nginx-proxy-manager': 'http://localhost:81',
'portainer': 'http://localhost:9000',
'uptime-kuma': 'http://localhost:3001',
'tailscale': 'http://localhost:8240',
'fedimint': 'http://localhost:8175',
'nostr-rs-relay': 'http://localhost:18081',
'dwn': 'http://localhost:3100',
'indeedhub': 'http://localhost:8190',
}
function launchInstalledApp(app: MarketplaceApp) {
const id = app.id
// Web-only apps
const webOnlyUrl = WEB_ONLY_APP_URLS[id]
if (webOnlyUrl) {
appLauncher.open({ url: webOnlyUrl, title: app.title || id })
return
}
// Web URL on the marketplace app object (e.g. Nostr-discovered apps)
if (app.webUrl) {
appLauncher.open({ url: app.webUrl, title: app.title || id })
return
}
// Container apps with known ports
const portUrl = APP_LAUNCH_URLS[id]
if (portUrl) {
let url = portUrl
if (url.includes('localhost')) {
url = url.replace('localhost', window.location.hostname)
}
appLauncher.open({ url, title: app.title || id })
return
}
// Fallback: navigate to the app detail page
router.push({ name: 'app-details', params: { id } })
appLauncher.openSession(app.id)
}
// Load community marketplace on mount