Add auto-discovery services tab using Coolify API
Replace static services list with dynamic discovery from Coolify's server resources API. Services are auto-categorized using a registry of known service names mapped to icons and categories. Falls back to static list with health checks when Coolify is unreachable. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -11,6 +11,14 @@ export interface Service {
|
||||
container?: string;
|
||||
}
|
||||
|
||||
export interface DiscoveredService extends Service {
|
||||
source: 'discovered' | 'static';
|
||||
fqdn?: string;
|
||||
resourceType: 'application' | 'service' | 'database';
|
||||
uuid: string;
|
||||
coolifyStatus: string;
|
||||
}
|
||||
|
||||
export interface Bookmark {
|
||||
name: string;
|
||||
url: string;
|
||||
@@ -19,7 +27,7 @@ export interface Bookmark {
|
||||
description?: string;
|
||||
}
|
||||
|
||||
export const services: Service[] = [
|
||||
export const fallbackServices: Service[] = [
|
||||
// Infrastructure
|
||||
{ name: 'Coolify', url: 'http://192.168.1.3:8000', port: 8000, icon: 'server', category: 'infrastructure', description: 'Container deployment & management' },
|
||||
{ name: 'Dozzle', url: 'http://192.168.1.3:9999', port: 9999, icon: 'scroll-text', category: 'infrastructure', description: 'Real-time Docker log viewer' },
|
||||
@@ -51,6 +59,9 @@ export const services: Service[] = [
|
||||
{ name: 'Authentik', url: 'http://192.168.1.3:9090', port: 9090, icon: 'shield', category: 'security', description: 'Identity provider & SSO' },
|
||||
];
|
||||
|
||||
// Re-export for backwards compatibility
|
||||
export const services = fallbackServices;
|
||||
|
||||
export const bookmarks: Bookmark[] = [
|
||||
// Developer Tools
|
||||
{ name: 'DevDocs', url: 'https://devdocs.io', icon: 'book', category: 'developer', description: 'API documentation browser' },
|
||||
|
||||
Reference in New Issue
Block a user