An open source, self-hosted, real-time port monitoring and discovery tool.
refactor(whatsnew): replace config-based curation with inline directives
Mostafa-Wahiedcd30315e3977
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex abe0ccd..aa0de2f 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -4,36 +4,54 @@ All notable changes to portracker will be documented in this file.## [Unreleased]-### Added--- **[Sidebar Controls]**: Desktop sidebar can now be resized, collapsed to a cleaner icon rail, and rediscovered with a one-time coachmark that points out the new controls.-- **[Keyboard Shortcuts]**: `Cmd/Ctrl+K` focuses search, `Escape` clears and blurs, `Cmd/Ctrl+B` toggles the sidebar, `Cmd/Ctrl+R` refreshes, and `1`–`9` quick-switch between servers.-- **[Server Health Indicator]**: Server cards in the sidebar now show a colored dot (green = online, red = unreachable, blue pulse = updating).-- **[Last Refreshed Timestamp]**: Each server card displays a live-updating "Updated Xm ago" label showing when data was last fetched.--### Fixed--- **[Status Dot Spacing]**: Restored the gap between the rolled-up service status dot and the service name in card headers.-- **[Status Wording]**: Updated copy on per-port indicators, the rolled-up status dot, and the "Why this status?" details so a published port that isn't reachable now reads clearly instead of using ambiguous "did not answer" / "not responding" phrasing.-- **[Status Dot Loading State]**: Service cards now show a soft pulsing dot while service health data is loading instead of briefly flashing red on services whose published ports were partially unreachable.-- **[Service Card Grouping]**: Containers that publish multiple ports now consolidate into a single service card instead of splitting into several rows when their compose labels were inconsistent across collection paths.+## [1.3.8] - 2026-05-04++### Dashboard & UX++<!-- whatsnew:title=Smarter, clearer service status -->+- **[Smarter Service Status]**: Service status with protocol-aware probes, helper-vs-main aggregation, and per-component overrides (resolves #88).+ - **[sub]** Protocol-aware probes for HTTP/HTTPS/TCP/UDP, container state, and finished jobs+ - **[sub]** Helper components degrade the service to yellow instead of turning the whole thing red+ - **[sub]** "Why this status?" popover shows the failing component, the rule that fired, and per-port evidence+ - **[sub]** Per-component role overrides; clear all from Settings > Advanced+ - **[sub]** Clearer port and rolled-up status wording+ - **[sub]** Soft pulsing dot while loading instead of briefly flashing red++<!-- whatsnew:title=Reorganized sidebar -->+- **[Sidebar Reorganization]**: Reorder, sort, resize, and collapse the sidebar, with per-server health and a refreshed timestamp.+ - **[sub]** Drag servers to reorder; order persists across reloads+ - **[sub]** Sort chip cycles Custom / A→Z / Z→A with an inline undo banner+ - **[sub]** Resizable, collapsible icon rail, one-time discovery coachmark+ - **[sub]** Per-server health dot (green / red / blue pulse)+ - **[sub]** Live "Updated Xm ago" label per server++<!-- whatsnew:title=Keyboard shortcuts -->+- **[Keyboard Shortcuts]**: `Cmd/Ctrl+K` focuses search, `Esc` clears, `Cmd/Ctrl+B` toggles the sidebar, `Cmd/Ctrl+R` refreshes, and `1`–`9` quick-switch between servers.## [1.3.7] - 2026-04-02### Fixed+<!-- whatsnew:title=Better service naming in stack deployments -->+<!-- whatsnew:description=Reduced false matches when containers share the same stack name. -->- **[Container Heuristic]**: Fixed `_getContainerByProcessName` false-positive — now checks image name instead of container name to avoid misattribution in stacks named `portracker-*` (#102 by @leinardi)+<!-- whatsnew:hide -->- **[Frontend Error Logging]**: Downgraded `ENOENT` log from error to debug when frontend is not built yet (#101 by @leinardi)+<!-- whatsnew:title=Better Docker service icons -->+<!-- whatsnew:description=Swarm services keep a recognizable Docker icon when the remote icon lookup fails. -->- **[Swarm Fallback Icon]**: Docker Swarm services now fall back to the Docker whale icon when CDN lookup fails (#103 by @leinardi)### Security+<!-- whatsnew:hide -->- **[npm Vulnerabilities]**: Removed unused root dependencies `jq`, `sqlite3`, and `react-router-dom` that pulled in critical/high transitive vulnerabilities (#100 by @leinardi)## [1.3.6] - 2026-04-02### Docker Swarm+<!-- whatsnew:title=Docker Swarm ingress ports group correctly -->+<!-- whatsnew:description=Ingress-mode published ports now stay attached to the right Docker service instead of falling back to system ports. -->- **[Swarm Ingress Support]**: Docker Swarm services using `mode: ingress` published ports are now correctly attributed as Docker services instead of system ports (#98, PR #99 by @leinardi)- **[sub]** Swarm port discovery via Docker Services API- **[sub]** Shared logic in BaseCollector for both Docker and TrueNAS collectors@@ -41,25 +59,35 @@ All notable changes to portracker will be documented in this file.### Fixed+<!-- whatsnew:hide -->- **[Port Dedup Key Consistency]**: Fixed inconsistent dedup key format between Docker and TrueNAS collectors — both now include protocol in the key+<!-- whatsnew:hide -->- **[CI]**: Fixed Docker build workflow failing on fork PRs due to missing secrets## [1.3.5] - 2026-03-02### Security+<!-- whatsnew:hide -->- **Remove Vulnerable SQLite System Packages**: Removed unused `libsqlite3-dev` and `sqlite3` system packages from Docker image to address CVE-2025-7458. portracker uses `better-sqlite3` which bundles its own SQLite 3.49.2 (not affected) and never used the system libraries.### Fixed+<!-- whatsnew:title=Safer TrueNAS API key transport -->+<!-- whatsnew:description=TrueNAS API key connections now stay on secure WebSocket endpoints. -->- **TrueNAS API Key Transport Security**: Enforced secure WebSocket usage for TrueNAS API key authentication by restricting secure mode to `wss://` endpoints and skipping insecure `ws://` endpoints.+<!-- whatsnew:hide -->- **TrueNAS WebSocket Base Handling**: In secure mode, `TRUENAS_WS_BASE` now upgrades insecure `ws://` values to `wss://` and ignores insecure explicit URLs.## [1.3.4] - 2026-02-05### Fixed+<!-- whatsnew:title=No more duplicate host-network services -->+<!-- whatsnew:description=Services using host networking no longer show up twice when discovered through multiple paths. -->- **Host-Network Service Deduplication**: Added logical deduplication for services using host networking so the same listener is not shown multiple times when discovered through both Docker and process-based collection paths (addresses #82)+<!-- whatsnew:title=Cleaner service port chips -->+<!-- whatsnew:description=Services no longer show repeated port chips when entries share the same host port. -->- **Service Port Rendering**: Updated service view port keys to use full port identity, avoiding repeated port chips when entries share the same host port number## [1.3.3] - 2026-02-05@@ -78,6 +106,8 @@ All notable changes to portracker will be documented in this file.### Fixed+<!-- whatsnew:title=Fresh installs work again -->+<!-- whatsnew:description=Fixed a missing column that broke brand-new installs on first launch. -->- **Database Schema**: Fixed missing `remote_api_key` column in initial database creation that caused "no such column" errors for fresh installations (resolves #82)## [1.3.0] - 2026-02-02@@ -91,57 +121,83 @@ All notable changes to portracker will be documented in this file.### Security+<!-- whatsnew:title=Secure peer-to-peer between instances -->+<!-- whatsnew:description=Generate API keys in Settings to securely connect portracker instances. -->- **API Key Authentication**: Secure peer-to-peer communication between portracker instances- **[sub]** Generate unique API keys for external access from Settings- **[sub]** Backward compatible - only required when remote server has authentication enabled+<!-- whatsnew:title=Endpoints protected when auth is on -->+<!-- whatsnew:description=All data endpoints now require auth when authentication is enabled. -->- **Endpoint Protection**: All data endpoints protected when authentication is enabled### Integrations+<!-- whatsnew:title=See what's exposed publicly -->+<!-- whatsnew:description=Connect an autoxpose instance in Settings to see public URLs next to your internal ports. -->- **autoxpose Integration**: See which services are publicly exposed by connecting to your autoxpose instance from Settings- **[sub]** Public URLs displayed alongside internal ports with SSL status indicators- **[sub]** Clickable links open your public endpoints directly### Settings+<!-- whatsnew:title=One place for settings -->+<!-- whatsnew:description=Theme, refresh interval, autoxpose connection, and advanced options live in a single modal. -->- **Settings Modal**: Centralized configuration accessible from header dropdown for theme, refresh intervals, autoxpose connection, and advanced options### Added+<!-- whatsnew:title=Works behind a reverse proxy -->+<!-- whatsnew:description=Set HOST_OVERRIDE to control the hostname used in port links. -->- **Reverse Proxy Support**: New `HOST_OVERRIDE` environment variable allows specifying the hostname used in port links when running behind a reverse proxy (fixes #51)### Fixed+<!-- whatsnew:title=System ports detected in containers -->+<!-- whatsnew:description=Restored SSH, SMB, and other system port detection inside containerized deployments. -->- **System Port Detection**: Restored system port detection (SSH, SMB, etc.) when running in containerized environments.### Dashboard+<!-- whatsnew:title=Ports grouped by service -->+<!-- whatsnew:description=Ports are now grouped by service in expandable cards. This is the default view. -->- **Service-Centric View**: View your ports organized by service name with expandable cards showing all ports per service (now the default view)+<!-- whatsnew:title=Service icons, theme-aware -->+<!-- whatsnew:description=Known services show icons that adapt to light and dark mode. -->- **Service Icons**: Visual icons automatically loaded for known services with theme-aware variants for dark and light modes### UI+<!-- whatsnew:title=Health at a glance when collapsed -->+<!-- whatsnew:description=Collapsed service cards now show an aggregated health indicator. -->- **Collapsed Health Status**: Collapsed service cards now show an aggregated health indicator so you can see status at a glance without expanding+<!-- whatsnew:title=Favicon follows your theme -->+<!-- whatsnew:description=The favicon now adapts to light and dark system themes. -->- **Favicon**: Dark mode support - favicon now adapts to system theme (black on light, white on dark)## [1.2.2] - 2025-12-12### Performance & Reliability+<!-- whatsnew:title=Faster, more reliable TrueNAS -->+<!-- whatsnew:description=Parallel API calls, per-call timeouts, and reused connections make TrueNAS collection steadier. -->- **TrueNAS Integration**: Improved timeout handling with parallel API calls, granular per-call timeouts, and connection reuse for reliable VM and container collection## [1.2.1] - 2025-11-21### Performance & Reliability+<!-- whatsnew:title=TrueNAS VMs and LXCs from the UI -->+<!-- whatsnew:description=Add a TrueNAS API key from Settings to see VM and LXC containers in your dashboard. -->- **TrueNAS Enhanced Features**: Fixed VM and LXC container cards disappearing after auto-refresh on resource-constrained systems## [1.2.0] - 2025-11-20### Security+<!-- whatsnew:title=Optional dashboard login -->+<!-- whatsnew:description=Turn on ENABLE_AUTH to protect the dashboard. Off by default. -->- **Authentication**: Optional authentication to secure dashboard access using `ENABLE_AUTH=true`- **[sub]** Disabled by default for backward compatibility- **[sub]** Recovery mode accessible via `RECOVERY_MODE=true` if you lose your password@@ -149,92 +205,140 @@ All notable changes to portracker will be documented in this file.### Dashboard+<!-- whatsnew:title=Auto-refresh every 30s -->+<!-- whatsnew:description=Toggle auto-refresh from the header to keep ports and services live. -->- **Auto-Refresh**: Added a toggle to auto-refresh ports and services every 30 seconds+<!-- whatsnew:title=Pick an unused port -->+<!-- whatsnew:description=One click to generate a port that isn't already taken. -->- **Random Port Generator**: Generate an unused port with a single click## [1.1.1] - 2025-01-17### Server Integrations+<!-- whatsnew:title=TrueNAS VMs and LXCs from the UI -->+<!-- whatsnew:description=Add a TrueNAS API key from Settings to see VM and LXC containers in your dashboard. -->- **TrueNAS Enhanced Features**: Add your TrueNAS API key directly from the UI to unlock VM and LXC container monitoring with step-by-step setup instructions### Fixes+<!-- whatsnew:hide -->- **TrueNAS API Key Revocation**: Fixed automatic key revocation issue by prioritizing secure WebSocket connections+<!-- whatsnew:title=VMs and LXCs look right -->+<!-- whatsnew:description=VMs and LXC containers now show correct icons and badges. -->- **Virtual Machines & Containers**: VMs and LXC containers now display correctly with icons and badges to distinguish between them+<!-- whatsnew:hide -->- **Debug Logging**: DEBUG environment variable now properly enables debug output## [1.1.0] - 2025-08-23### Dashboard+<!-- whatsnew:hide -->- **System Port Name Fix**: Fixed the issue where system ports were incorrectly displayed as "unknown".+<!-- whatsnew:hide -->- **Consistent Status Indicators**: Improved status indicators for system ports to ensure consistency.## [1.0.8] - 2025-08-20### Dashboard+<!-- whatsnew:hide -->- **Batch rename migration fix**: Fix migration issue affecting batch rename operations so renamed services persist correctly.+<!-- whatsnew:hide -->- **Misc.**: minor migration-related fix for batch rename flow.## [1.0.7] - 2025-08-19### Dashboard+<!-- whatsnew:title=Rename services from the UI -->+<!-- whatsnew:description=You can rename services directly in the dashboard. -->- **Service renaming**: Allow renaming services from the UI.+<!-- whatsnew:title=Bulk actions on ports -->+<!-- whatsnew:description=Select multiple services or ports to ignore or annotate them at once. -->- **Batch actions**: Add selection and batch operations for services and ports (ignore, add note, etc.).+<!-- whatsnew:hide -->- **Internal / Port display fixes**: Fix display issues so internal and published ports are shown correctly; fix select-box overlap.### Backend+<!-- whatsnew:hide -->- **Port protocol reporting**: Ensure ports include protocol information so reported mappings are accurate.## [1.0.6] - 2025-08-15### Dashboard+<!-- whatsnew:title=Container details drawer -->+<!-- whatsnew:description=Slide-out panel with stats, labels, mounts, and env vars for Docker containers. -->- **Container Details Drawer**: New slide-out panel to show detailed information for Docker containers including stats, labels, mounts, and environment variables+<!-- whatsnew:title=Internal vs published ports, clear -->+<!-- whatsnew:description=Internal-only ports are now clearly distinguished from published ones, with health status. -->- **Internal Port Display**: UI now correctly shows and differentiates internal-only ports from published ports with health status monitoring+<!-- whatsnew:title=Search across all servers -->+<!-- whatsnew:description=The search bar can search every connected server at once. -->- **Global Search**: Search bar now includes an option to search across all servers simultaneously+<!-- whatsnew:title=Release notes modal -->+<!-- whatsnew:description=portracker tells you what changed when you open a new version. -->- **What's New**: Automatic notification system to stay updated with new features when releasing new versions### Data+<!-- whatsnew:title=Faster refreshes -->+<!-- whatsnew:description=Data collectors now cache between refreshes to reduce duplicate work. -->- **Collector Caching**: Added caching mechanism to all data collectors to reduce duplicate requests and improve data refresh speed## [1.0.5] - 2025-08-09### Server Integrations+<!-- whatsnew:hide -->- **Dockerode Integration**: Switched to use the dockerode library for more reliable Docker API interactions instead of shell commands+<!-- whatsnew:hide -->- **Centralized Logging**: All collectors now use a single Logger class for consistent and structured logging throughout the application## [1.0.4] - 2025-08-09### Dashboard+<!-- whatsnew:title=Better service detection -->+<!-- whatsnew:description=Improved identification and categorization of running services, including SPA apps. -->- **Enhanced Service Detection**: Improved identification and categorization of running services with Single Page Application (SPA) detection support+<!-- whatsnew:title=Clearer port status -->+<!-- whatsnew:description=Visual distinction between published and internal ports, with detailed status. -->- **Port Status Indicators**: Added clear visual distinction between different types of ports (published vs internal) with detailed status information### Server Integrations+<!-- whatsnew:title=No host networking required -->+<!-- whatsnew:description=Direct /proc parsing replaces the need for Docker host networking mode. -->- **Removed network_mode: host Requirement**: Eliminated the need for Docker host networking mode by implementing direct /proc filesystem parsing for better security+<!-- whatsnew:title=More accurate port detection -->+<!-- whatsnew:description=Multiple detection methods improve container and system port identification. -->- **Advanced Port Detection**: Enhanced system for more accurate container and system port identification using multiple detection methods+<!-- whatsnew:title=Steadier container collection -->+<!-- whatsnew:description=Better error handling and fallbacks across platforms for reliable port collection. -->- **Improved Container Introspection**: Better error handling and fallback strategies across different platforms for reliable port collection## [1.0.3] - 2025-08-07### Data+<!-- whatsnew:title=Simpler Docker setup -->+<!-- whatsnew:description=No extra system socket mounts required, and Docker proxy is supported. -->- **Simplified Docker Dependencies**: Streamlined system requirements - no longer requires mounting additional system sockets for container information and support for docker proxy.+<!-- whatsnew:title=More accurate container metadata -->+<!-- whatsnew:description=Timestamps and metadata parsing are more precise. -->- **Enhanced Data Accuracy**: Improved container information display with more accurate timestamps and metadata parsing## [1.0.2] - 2025-07-11### Security+<!-- whatsnew:hide -->- **Security Hardening**: Key security aspects addressed+<!-- whatsnew:hide -->- **Data Collection**: Improved data collection accuracy## [1.0.1] - 2025-07-10@@ -247,7 +351,12 @@ All notable changes to portracker will be documented in this file.### Dashboard+<!-- whatsnew:title=portracker is out -->+<!-- whatsnew:description=Monitor ports across multiple servers from one dashboard. -->- **Multi-platform Port Tracking**: Initial release of portracker with support for monitoring ports across multiple servers+<!-- whatsnew:hide -->- **Docker Integration**: Native Docker container port monitoring+<!-- whatsnew:hide -->- **Web Interface**: Clean, responsive web interface for port management+<!-- whatsnew:hide -->- **Server Management**: Support for multiple server configurationsdiff --git a/frontend/src/lib/whats-new-config.js b/frontend/src/lib/whats-new-config.jsindex 6f3c72d..138ac2a 100644--- a/frontend/src/lib/whats-new-config.js+++ b/frontend/src/lib/whats-new-config.js@@ -3,220 +3,7 @@ const whatsNewConfig = {{ versions: ['1.3.1', '1.3.2', '1.3.3', '1.3.4'], mergeTitles: ['Duplicate Ports'] }],ignoreVersions: ['Unreleased'],- maxVersionsOnFirstOpen: 1,- hiddenTitles: [- 'Frontend Error Logging',- 'CI',- 'npm Vulnerabilities',- 'Remove Vulnerable SQLite System Packages',- 'Port Dedup Key Consistency',- 'TrueNAS WebSocket Base Handling',- 'TrueNAS API Key Revocation',- 'Debug Logging',- 'Internal / Port display fixes',- 'Port protocol reporting',- 'Batch rename migration fix',- 'Misc.',- 'System Port Name Fix',- 'Consistent Status Indicators',- 'Dockerode Integration',- 'Centralized Logging',- 'Security Hardening',- 'Data Collection',- 'Docker Integration',- 'Web Interface',- 'Server Management'- ],- featureOverrides: {- 'Sidebar Reordering': {- title: 'Drag-and-drop sidebar order',- description: 'Reorder servers by dragging; the order persists across reloads and prioritizes autoxpose suggestions based on your custom order.'- },- 'Sidebar Sort Modes': {- title: 'Custom and alphabetical sort modes',- description: 'A sidebar chip cycles through Custom, A→Z, and Z→A. Alphabetical modes are view-only, with an undo banner to revert.'- },- 'Sidebar Controls': {- title: 'Resizable, collapsible sidebar',- description: 'Resize the desktop sidebar or collapse it to an icon rail; a one-time coachmark points out the new controls.'- },- 'Keyboard Shortcuts': {- title: 'Keyboard shortcuts',- description: 'Cmd/Ctrl+K focuses search, Esc clears, Cmd/Ctrl+B toggles the sidebar, Cmd/Ctrl+R refreshes, and 1–9 quick-switch between servers.'- },- 'Server Health Indicator': {- title: 'Server health at a glance',- description: 'Sidebar server cards show a colored dot — green for online, red for unreachable, a blue pulse while updating.'- },- 'Last Refreshed Timestamp': {- title: '"Updated Xm ago" on every server',- description: 'Each server card shows a live-updating timestamp of when its data was last fetched.'- },- 'Status Wording': {- title: 'Clearer port status wording',- description: 'Updated copy on per-port indicators and the rolled-up status dot so an unreachable published port reads clearly.'- },- 'Status Dot Loading State': {- title: 'Smoother loading state',- description: 'Service cards show a soft pulsing dot while health data is loading instead of briefly flashing red.'- },- 'Service Card Grouping': {- title: 'Consolidated multi-port services',- description: 'Containers publishing multiple ports now group into a single service card instead of splitting on inconsistent compose labels.'- },- 'Container Heuristic': {- title: 'Better service naming in stack deployments',- description: 'Reduced false matches when containers share the same stack name.'- },- 'Swarm Fallback Icon': {- title: 'Better Docker service icons',- description: 'Swarm services keep a recognizable Docker icon when the remote icon lookup fails.'- },- 'Swarm Ingress Support': {- title: 'Docker Swarm ingress ports group correctly',- description: 'Ingress-mode published ports now stay attached to the right Docker service instead of falling back to system ports.'- },- 'TrueNAS API Key Transport Security': {- title: 'Safer TrueNAS API key transport',- description: 'TrueNAS API key connections now stay on secure WebSocket endpoints.'- },- 'Host-Network Service Deduplication': {- title: 'No more duplicate host-network services',- description: 'Services using host networking no longer show up twice when discovered through multiple paths.'- },- 'Service Port Rendering': {- title: 'Cleaner service port chips',- description: 'Services no longer show repeated port chips when entries share the same host port.'- },- 'Database Schema': {- title: 'Fresh installs work again',- description: 'Fixed a missing column that broke brand-new installs on first launch.'- },- 'API Key Authentication': {- title: 'Secure peer-to-peer between instances',- description: 'Generate API keys in Settings to securely connect portracker instances.'- },- 'Endpoint Protection': {- title: 'Endpoints protected when auth is on',- description: 'All data endpoints now require auth when authentication is enabled.'- },- 'autoxpose Integration': {- title: "See what's exposed publicly",- description: 'Connect an autoxpose instance in Settings to see public URLs next to your internal ports.'- },- 'Settings Modal': {- title: 'One place for settings',- description: 'Theme, refresh interval, autoxpose connection, and advanced options live in a single modal.'- },- 'Reverse Proxy Support': {- title: 'Works behind a reverse proxy',- description: 'Set HOST_OVERRIDE to control the hostname used in port links.'- },- 'System Port Detection': {- title: 'System ports detected in containers',- description: 'Restored SSH, SMB, and other system port detection inside containerized deployments.'- },- 'Service-Centric View': {- title: 'Ports grouped by service',- description: 'Ports are now grouped by service in expandable cards. This is the default view.'- },- 'Service Icons': {- title: 'Service icons, theme-aware',- description: 'Known services show icons that adapt to light and dark mode.'- },- 'Collapsed Health Status': {- title: 'Health at a glance when collapsed',- description: 'Collapsed service cards now show an aggregated health indicator.'- },- 'Favicon': {- title: 'Favicon follows your theme',- description: 'The favicon now adapts to light and dark system themes.'- },- 'TrueNAS Integration': {- title: 'Faster, more reliable TrueNAS',- description: 'Parallel API calls, per-call timeouts, and reused connections make TrueNAS collection steadier.'- },- 'TrueNAS Enhanced Features': {- title: 'TrueNAS VMs and LXCs from the UI',- description: 'Add a TrueNAS API key from Settings to see VM and LXC containers in your dashboard.'- },- 'Authentication': {- title: 'Optional dashboard login',- description: 'Turn on ENABLE_AUTH to protect the dashboard. Off by default.'- },- 'Auto-Refresh': {- title: 'Auto-refresh every 30s',- description: 'Toggle auto-refresh from the header to keep ports and services live.'- },- 'Random Port Generator': {- title: 'Pick an unused port',- description: "One click to generate a port that isn't already taken."- },- 'Virtual Machines & Containers': {- title: 'VMs and LXCs look right',- description: 'VMs and LXC containers now show correct icons and badges.'- },- 'Service renaming': {- title: 'Rename services from the UI',- description: 'You can rename services directly in the dashboard.'- },- 'Batch actions': {- title: 'Bulk actions on ports',- description: 'Select multiple services or ports to ignore or annotate them at once.'- },- 'Container Details Drawer': {- title: 'Container details drawer',- description: 'Slide-out panel with stats, labels, mounts, and env vars for Docker containers.'- },- 'Internal Port Display': {- title: 'Internal vs published ports, clear',- description: 'Internal-only ports are now clearly distinguished from published ones, with health status.'- },- 'Global Search': {- title: 'Search across all servers',- description: 'The search bar can search every connected server at once.'- },- "What's New": {- title: 'Release notes modal',- description: 'portracker tells you what changed when you open a new version.'- },- 'Collector Caching': {- title: 'Faster refreshes',- description: 'Data collectors now cache between refreshes to reduce duplicate work.'- },- 'Enhanced Service Detection': {- title: 'Better service detection',- description: 'Improved identification and categorization of running services, including SPA apps.'- },- 'Port Status Indicators': {- title: 'Clearer port status',- description: 'Visual distinction between published and internal ports, with detailed status.'- },- 'Removed network_mode: host Requirement': {- title: 'No host networking required',- description: 'Direct /proc parsing replaces the need for Docker host networking mode.'- },- 'Advanced Port Detection': {- title: 'More accurate port detection',- description: 'Multiple detection methods improve container and system port identification.'- },- 'Improved Container Introspection': {- title: 'Steadier container collection',- description: 'Better error handling and fallbacks across platforms for reliable port collection.'- },- 'Simplified Docker Dependencies': {- title: 'Simpler Docker setup',- description: 'No extra system socket mounts required, and Docker proxy is supported.'- },- 'Enhanced Data Accuracy': {- title: 'More accurate container metadata',- description: 'Timestamps and metadata parsing are more precise.'- },- 'Multi-platform Port Tracking': {- title: 'portracker is out',- description: 'Monitor ports across multiple servers from one dashboard.'- }- }+ maxVersionsOnFirstOpen: 1};export default whatsNewConfig;diff --git a/frontend/src/lib/whats-new.js b/frontend/src/lib/whats-new.jsindex d42abea..0d3e687 100644--- a/frontend/src/lib/whats-new.js+++ b/frontend/src/lib/whats-new.js@@ -54,23 +54,26 @@ function shouldIgnoreVersion(version) {return ignoredVersions.includes(version) || !SEMVER_PATTERN.test(version);}-function applyFeatureOverrides(feature) {- const hiddenTitles = new Set((whatsNewConfig.hiddenTitles || []).map((title) => title.toLowerCase()));- const normalizedTitle = normalizeFeatureTitle(feature.title);+const DIRECTIVE_PATTERN = /^<!--\s*whatsnew:([a-z]+)(?:=(.*?))?\s*-->\s*$/i;- if (hiddenTitles.has(normalizedTitle.toLowerCase())) {- return null;- }+function emptyDirectives() {+ return { hide: false, title: null, description: null };+}- const override = whatsNewConfig.featureOverrides?.[normalizedTitle];- if (override?.hidden) {- return null;- }+function parseDirectiveLine(line) {+ const match = line.match(DIRECTIVE_PATTERN);+ if (!match) return null;+ const key = match[1].toLowerCase();+ const value = match[2] !== undefined ? match[2].trim() : null;+ return { key, value };+}+function applyDirectives(feature, directives) {+ if (directives.hide) return null;return {...feature,- title: override?.title || normalizedTitle,- description: override?.description || normalizeFeatureDescription(feature.description),+ title: directives.title || normalizeFeatureTitle(feature.title),+ description: directives.description || normalizeFeatureDescription(feature.description),details: Array.isArray(feature.details)? feature.details.map((detail) => ({@@ -112,12 +115,23 @@ export function parseChangelog(changelogContent) {let inHighlights = false;let features = createFeatureBuckets();let lastFeature = null;+ let pendingDirectives = emptyDirectives();for (let i = 0; i < lines.length; i++) {- const line = lines[i].trim();+ const rawLine = lines[i];+ const line = rawLine.trim();++ const directive = parseDirectiveLine(line);+ if (directive) {+ if (directive.key === 'hide') pendingDirectives.hide = true;+ else if (directive.key === 'title') pendingDirectives.title = directive.value;+ else if (directive.key === 'description') pendingDirectives.description = directive.value;+ continue;+ }if (line === '**Highlights**') {inHighlights = true;+ pendingDirectives = emptyDirectives();continue;}@@ -126,6 +140,7 @@ export function parseChangelog(changelogContent) {if (line.startsWith('###')) {currentSection = mapSectionToCategory(line.replace(/^###\s+/, ''));}+ pendingDirectives = emptyDirectives();continue;}@@ -135,6 +150,7 @@ export function parseChangelog(changelogContent) {const title = parts[0]?.trim() || highlightText;const description = parts[1]?.trim() || '';features.highlights.push({ title, description });+ pendingDirectives = emptyDirectives();continue;}@@ -144,17 +160,19 @@ export function parseChangelog(changelogContent) {if (currentVersion && hasContent) {versions[currentVersion] = { ...features };}-+currentVersion = versionMatch[1];if (shouldIgnoreVersion(currentVersion)) {currentSection = null;features = createFeatureBuckets();lastFeature = null;+ pendingDirectives = emptyDirectives();continue;}currentSection = null;features = createFeatureBuckets();lastFeature = null;+ pendingDirectives = emptyDirectives();continue;}@@ -162,6 +180,7 @@ export function parseChangelog(changelogContent) {if (sectionMatch && currentVersion) {currentSection = mapSectionToCategory(sectionMatch[1]);lastFeature = null;+ pendingDirectives = emptyDirectives();continue;}@@ -169,9 +188,9 @@ export function parseChangelog(changelogContent) {if (featureMatch && currentSection) {const title = featureMatch[1].trim();const description = featureMatch[2].trim();-+const isSubItem = title.startsWith('[sub]');-+if (isSubItem && lastFeature) {const cleanTitle = title.replace(/^\[sub\]\s*/, '').trim();if (!lastFeature.details) {@@ -179,12 +198,12 @@ export function parseChangelog(changelogContent) {}lastFeature.details.push({ title: cleanTitle, description });} else {- const nextFeature = applyFeatureOverrides({+ const nextFeature = applyDirectives({title: isSubItem ? title.replace(/^\[sub\]\s*/, '').trim() : title,description,details: []- });-+ }, pendingDirectives);+if (nextFeature) {features[currentSection].push(nextFeature);lastFeature = nextFeature;@@ -192,6 +211,7 @@ export function parseChangelog(changelogContent) {lastFeature = null;}}+ pendingDirectives = emptyDirectives();continue;}@@ -202,6 +222,7 @@ export function parseChangelog(changelogContent) {lastFeature.details = [];}lastFeature.details.push({ title: '', description: normalizeFeatureDescription(text) });+ pendingDirectives = emptyDirectives();}}diff --git a/scripts/generate-release-notes.mjs b/scripts/generate-release-notes.mjsindex 255fecc..348e49a 100644--- a/scripts/generate-release-notes.mjs+++ b/scripts/generate-release-notes.mjs@@ -1,6 +1,6 @@#!/usr/bin/env nodeimport { readFileSync } from "node:fs";-import { fileURLToPath, pathToFileURL } from "node:url";+import { fileURLToPath } from "node:url";import { dirname, resolve } from "node:path";const __filename = fileURLToPath(import.meta.url);@@ -16,16 +16,6 @@ if (!version) {process.exit(1);}-const configUrl = pathToFileURL(- resolve(repoRoot, "frontend/src/lib/whats-new-config.js")-).href;-const { default: whatsNewConfig } = await import(configUrl);--const hiddenTitles = new Set(- (whatsNewConfig.hiddenTitles || []).map((title) => title.toLowerCase())-);-const featureOverrides = whatsNewConfig.featureOverrides || {};-const changelog = readFileSync(resolve(repoRoot, "CHANGELOG.md"), "utf8");const lines = changelog.split("\n");@@ -58,24 +48,24 @@ function normalizeDescription(text) {.trim();}+const DIRECTIVE_PATTERN = /^\s*<!--\s*whatsnew:([a-z]+)(?:=(.*?))?\s*-->\s*$/i;+function emptyDirectives() {+ return { hide: false, title: null, description: null };+}+const highlights = [];let inHighlights = false;for (const raw of captured) {const line = raw.trim();- if (line === "**Highlights**") {- inHighlights = true;- continue;- }- if (inHighlights && (line === "---" || line.startsWith("###"))) {- inHighlights = false;- continue;- }+ if (line === "**Highlights**") { inHighlights = true; continue; }+ if (inHighlights && (line === "---" || line.startsWith("###"))) { inHighlights = false; continue; }if (inHighlights && line.startsWith("- ")) {const text = line.replace(/^-\s*/, "");const parts = text.split(/\s+[\-\u2013\u2014]\s+/);- const title = (parts[0] || text).trim();- const description = (parts.slice(1).join(" \u2014 ") || "").trim();- highlights.push({ title, description });+ highlights.push({+ title: (parts[0] || text).trim(),+ description: (parts.slice(1).join(" \u2014 ") || "").trim(),+ });}}@@ -86,19 +76,29 @@ const out = [];let lastVisible = true;let currentSection = null;let sectionHasContent = false;+let pendingDirectives = emptyDirectives();for (const raw of captured) {const line = raw.trimEnd();+ const directive = line.match(DIRECTIVE_PATTERN);+ if (directive) {+ const key = directive[1].toLowerCase();+ const value = directive[2] !== undefined ? directive[2].trim() : null;+ if (key === "hide") pendingDirectives.hide = true;+ else if (key === "title") pendingDirectives.title = value;+ else if (key === "description") pendingDirectives.description = value;+ continue;+ }+const sectionMatch = line.match(/^###\s+(.+)$/);if (sectionMatch) {- if (currentSection && sectionHasContent) {- out.push("");- }+ if (currentSection && sectionHasContent) out.push("");currentSection = sectionMatch[1].trim();sectionHasContent = false;out.push(`### ${currentSection}`);out.push("");+ pendingDirectives = emptyDirectives();continue;}@@ -106,6 +106,7 @@ for (const raw of captured) {if (subMatch && lastVisible) {out.push(` - ${normalizeDescription(subMatch[1])}`);sectionHasContent = true;+ pendingDirectives = emptyDirectives();continue;}@@ -113,20 +114,17 @@ for (const raw of captured) {if (match) {const title = match[1].trim();const description = match[2].trim();- if (hiddenTitles.has(title.toLowerCase())) {+ if (pendingDirectives.hide) {lastVisible = false;+ pendingDirectives = emptyDirectives();continue;}- const override = featureOverrides[title];- if (override?.hidden) {- lastVisible = false;- continue;- }- const finalTitle = override?.title || title;- const finalDescription = override?.description || normalizeDescription(description);+ const finalTitle = pendingDirectives.title || title;+ const finalDescription = pendingDirectives.description || normalizeDescription(description);out.push(`- **${finalTitle}**: ${finalDescription}`);sectionHasContent = true;lastVisible = true;+ pendingDirectives = emptyDirectives();continue;}@@ -144,10 +142,7 @@ for (let i = 0; i < out.length; i++) {let hasContent = false;for (let j = i + 1; j < out.length; j++) {if (/^###\s+/.test(out[j])) break;- if (/^\s*-\s/.test(out[j])) {- hasContent = true;- break;- }+ if (/^\s*-\s/.test(out[j])) { hasContent = true; break; }}if (!hasContent) {if (i + 1 < out.length && out[i + 1].trim() === "") i++;@@ -165,19 +160,16 @@ const compareUrl = previousVersionconst bodyLines = [`## What's New in ${version}`, ""];if (highlights.length > 0) {+ bodyLines.push("### Highlights", "");for (const h of highlights) {- if (h.description) {- bodyLines.push(`- **${h.title}** \u2014 ${h.description}`);- } else {- bodyLines.push(`- **${h.title}**`);- }+ if (h.description) bodyLines.push(`- **${h.title}** \u2014 ${h.description}`);+ else bodyLines.push(`- **${h.title}**`);}-} else {- bodyLines.push(...filtered);+ bodyLines.push("");}-bodyLines.push("", `**Full Changelog**: ${compareUrl}`, "");+if (filtered.length > 0) bodyLines.push(...filtered);-const body = bodyLines.join("\n");+bodyLines.push("", `**Full Changelog**: ${compareUrl}`, "");-process.stdout.write(body);+process.stdout.write(bodyLines.join("\n"));