Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.
Go aialertsdashboarddockerdocker-monitoringgohomelabinfrastructure-monitoringkubernetesmonitoringmspproxmoxproxmox-backup-serverproxmox-mail-gatewayproxmox-veself-hostedtruenastypescriptvspherewebhooks
fix: skip update check for source builds and show appropriate UI message
rcourtman66b97333f722
diff --git a/frontend-modern/src/api/updates.ts b/frontend-modern/src/api/updates.tsindex 9ee9c2c430..b2a8a20e70 100644--- a/frontend-modern/src/api/updates.ts+++ b/frontend-modern/src/api/updates.ts@@ -26,6 +26,7 @@ export interface VersionInfo {runtime: string;channel?: string;isDocker: boolean;+ isSourceBuild: boolean;isDevelopment: boolean;deploymentType?: string;}diff --git a/frontend-modern/src/components/Settings/Settings.tsx b/frontend-modern/src/components/Settings/Settings.tsxindex 1326fc0fd5..4a8decee69 100644--- a/frontend-modern/src/components/Settings/Settings.tsx+++ b/frontend-modern/src/components/Settings/Settings.tsx@@ -3257,9 +3257,13 @@ const Settings: Component<SettingsProps> = (props) => {<buttontype="button"onClick={checkForUpdates}- disabled={checkingForUpdates() || versionInfo()?.isDocker}+ disabled={+ checkingForUpdates() ||+ versionInfo()?.isDocker ||+ versionInfo()?.isSourceBuild+ }class={`px-4 py-2 text-sm rounded-lg transition-colors flex items-center gap-2 ${- versionInfo()?.isDocker+ versionInfo()?.isDocker || versionInfo()?.isSourceBuild? 'bg-gray-100 dark:bg-gray-700 text-gray-400 dark:text-gray-500 cursor-not-allowed': 'bg-blue-600 text-white hover:bg-blue-700'}`}@@ -3284,6 +3288,15 @@ const Settings: Component<SettingsProps> = (props) => {</div></Show>+ <Show when={versionInfo()?.isSourceBuild}>+ <div class="p-3 bg-blue-50 dark:bg-blue-900/20 border border-blue-200 dark:border-blue-800 rounded-lg">+ <p class="text-xs text-blue-800 dark:text-blue-200">+ <strong>Built from source:</strong> Pull the latest code from git and+ rebuild to update.+ </p>+ </div>+ </Show>+<Show when={Boolean(updateInfo()?.warning)}><div class="p-3 bg-amber-50 dark:bg-amber-900/20 border border-amber-200 dark:border-amber-700 rounded-lg"><p class="text-xs text-amber-800 dark:text-amber-200">diff --git a/frontend-modern/src/stores/updates.ts b/frontend-modern/src/stores/updates.tsindex d754aed476..c20643ea53 100644--- a/frontend-modern/src/stores/updates.ts+++ b/frontend-modern/src/stores/updates.ts@@ -100,7 +100,7 @@ const checkForUpdates = async (force = false): Promise<void> => {}// Don't check for updates in Docker or development builds- if (version.isDocker || version.isDevelopment) {+ if (version.isDocker || version.isDevelopment || version.isSourceBuild) {setUpdateAvailable(false);setUpdateInfo(null);return;diff --git a/internal/api/router.go b/internal/api/router.goindex ac29b059c3..f6884abed3 100644--- a/internal/api/router.go+++ b/internal/api/router.go@@ -2244,6 +2244,7 @@ func (r *Router) handleVersion(w http.ResponseWriter, req *http.Request) {Runtime: runtime.Version(),Channel: "stable",IsDocker: false,+ IsSourceBuild: false,IsDevelopment: true,}w.Header().Set("Content-Type", "application/json")@@ -2260,6 +2261,7 @@ func (r *Router) handleVersion(w http.ResponseWriter, req *http.Request) {Runtime: versionInfo.Runtime,Channel: versionInfo.Channel,IsDocker: versionInfo.IsDocker,+ IsSourceBuild: versionInfo.IsSourceBuild,IsDevelopment: versionInfo.IsDevelopment,DeploymentType: versionInfo.DeploymentType,}diff --git a/internal/api/types.go b/internal/api/types.goindex 622ec8904e..2eaf077b75 100644--- a/internal/api/types.go+++ b/internal/api/types.go@@ -29,6 +29,7 @@ type VersionResponse struct {Runtime string `json:"runtime,omitempty"`Channel string `json:"channel,omitempty"`IsDocker bool `json:"isDocker"`+ IsSourceBuild bool `json:"isSourceBuild"`IsDevelopment bool `json:"isDevelopment"`DeploymentType string `json:"deploymentType,omitempty"`UpdateAvailable bool `json:"updateAvailable"`diff --git a/internal/updates/manager.go b/internal/updates/manager.goindex a24f96ac36..4e9cbcce78 100644--- a/internal/updates/manager.go+++ b/internal/updates/manager.go@@ -164,6 +164,23 @@ func (m *Manager) CheckForUpdatesWithChannel(ctx context.Context, channel stringreturn info, nil}+ // Skip update check for source builds+ if currentInfo.IsSourceBuild {+ info := &UpdateInfo{+ Available: false,+ CurrentVersion: currentInfo.Version,+ LatestVersion: currentInfo.Version,+ }+ if useCache {+ m.statusMu.Lock()+ m.checkCache[channel] = info+ m.cacheTime[channel] = time.Now()+ m.statusMu.Unlock()+ }+ m.updateStatus("idle", 0, "Updates not available for source builds")+ return info, nil+ }+// Parse current version firstcurrentVer, err := ParseVersion(currentInfo.Version)if err != nil {diff --git a/internal/updates/version.go b/internal/updates/version.goindex 7a3fade698..1375044be8 100644--- a/internal/updates/version.go+++ b/internal/updates/version.go@@ -28,6 +28,7 @@ type VersionInfo struct {Runtime string `json:"runtime"`Channel string `json:"channel,omitempty"`IsDocker bool `json:"isDocker"`+ IsSourceBuild bool `json:"isSourceBuild"`IsDevelopment bool `json:"isDevelopment"`DeploymentType string `json:"deploymentType"`}@@ -128,6 +129,7 @@ func GetCurrentVersion() (*VersionInfo, error) {Channel: detectChannelFromVersion(normalized),IsDevelopment: isDev,IsDocker: isDockerEnvironment(),+ IsSourceBuild: isSourceBuildEnvironment(),DeploymentType: GetDeploymentType(),}}@@ -287,6 +289,23 @@ func isDockerEnvironment() bool {return false}+// isSourceBuildEnvironment checks if running from a source build+func isSourceBuildEnvironment() bool {+ markerPaths := []string{+ "BUILD_FROM_SOURCE",+ "/opt/pulse/BUILD_FROM_SOURCE",+ filepath.Join(filepath.Dir(os.Args[0]), "BUILD_FROM_SOURCE"),+ }++ for _, path := range markerPaths {+ if fileExists(path) {+ return true+ }+ }++ return false+}+// fileExists checks if a file existsfunc fileExists(path string) bool {// Use os.Stat instead of exec.Command for better performance and reliability@@ -301,6 +320,10 @@ func GetDeploymentType() string {return "docker"}+ if isSourceBuildEnvironment() {+ return "source"+ }+// Check for ProxmoxVE LXC installation (has update command)if fileExists("/bin/update") {// Read file directly instead of using exec.Command