Skip to content

feat: Clusters, container resource management and server info views#48

Merged
nfebe merged 7 commits intomainfrom
feat/ui-clusters-server-info-resources
Mar 18, 2026
Merged

feat: Clusters, container resource management and server info views#48
nfebe merged 7 commits intomainfrom
feat/ui-clusters-server-info-resources

Conversation

@nfebe
Copy link
Contributor

@nfebe nfebe commented Mar 18, 2026

Add new views to manage container resources allocation, cluster management (each agent server is a peer), and implementation of basic server info

nfebe added 6 commits March 18, 2026 14:50
Display server hostname, public IPs, network health status,
DNS resolver checks, and network interfaces under System nav.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
Place nav-count badges after the label text and use margin-left
auto so counts align to the right edge for better readability.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
Renamed the dashboard section to avoid confusion with deployment
quick actions. Added Server Info shortcut linking to the new view.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
View and update CPU, memory, swap, and CPU shares for containers.
Accessible from both the containers list and deployment detail
service actions.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
Cluster page showing status, peer list, invite generation, join
flow, and peer removal. Added cluster permissions to type system
and navigation under System group.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
Replace static "Local Environment" with dynamic dropdown showing
current server name fetched from cluster API, listing cluster peers
and linking to cluster management. Also show node count badge on
Cluster nav item.

Signed-off-by: nfebe <fenn25.fn@gmail.com>
@sourceant
Copy link

sourceant bot commented Mar 18, 2026

Code Review Summary

This PR introduces cluster management, container resource tuning, and server information views. It effectively expands the infrastructure management capabilities of the UI.

🚀 Key Improvements

  • Implemented ContainerResourcesModal for live tuning of Docker limits.
  • Added ClusterView to manage multi-server setups (peers).
  • Introduced ServerInfoView for host-level networking and health diagnostics.
  • Updated DashboardLayout with a server selector/environment switcher.

💡 Minor Suggestions

  • Centralize byte formatting utilities.
  • Add client-side validation for memory vs swap limits.
  • Include cluster status in the periodic polling interval.

Copy link

@sourceant sourceant bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review complete. See the overview comment for a summary.

};

const saveResources = async () => {
if (!props.containerId || !hasChanges.value) return;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When calling hasChanges.value, the logic depends on resources.value. However, the API call below does not verify if resources.value is still defined before accessing its properties. While unlikely given the v-else-if in the template, a defensive check or local constant is safer.

Suggested change
if (!props.containerId || !hasChanges.value) return;
const current = resources.value;
if (!props.containerId || !hasChanges.value || !current) return;

}
};

const copyToken = async () => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The navigator.clipboard.writeText API is only available in secure contexts (HTTPS or localhost). It's good practice to provide a fallback or check for existence to prevent runtime errors in non-standard environments.

Suggested change
const copyToken = async () => {
const copyToken = async () => {
if (!navigator.clipboard) {
notifications.error("Error", "Clipboard API not available");
return;
}
await navigator.clipboard.writeText(inviteToken.value);

Signed-off-by: nfebe <fenn25.fn@gmail.com>
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Mar 18, 2026

Deploying flatrun-ui with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0fc08d2
Status: ✅  Deploy successful!
Preview URL: https://04fdef1d.flatrun-ui.pages.dev
Branch Preview URL: https://feat-ui-clusters-server-info.flatrun-ui.pages.dev

View logs

Copy link

@sourceant sourceant bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review complete. See the overview comment for a summary.

@nfebe nfebe merged commit c7de791 into main Mar 18, 2026
5 checks passed
@nfebe nfebe deleted the feat/ui-clusters-server-info-resources branch March 18, 2026 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant