Raw <button> elements default to type="submit" inside a form, causing accidental
submits. Added an explicit type="button" to the 234 raw buttons (across 60
files) that have an onClick and no type — i.e. action buttons, which are never
the intended default-submit. Default-submit buttons (no onClick) and the shadcn
ui/* wrappers were left untouched. Applied via a brace/quote-aware scan so
multi-line tags and style={{...}} attrs are handled correctly.
Verified: npm run build passes; dashboard/services/settings screenshots render
unchanged.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Second ResourceListPage consumer (the page Services' chrome was copied from).
Replaced WordPress.jsx's duplicated .wp-list toolbar/bulk-bar + inline sk-dtable
table with ResourceListPage; the table is now DataTable columns. Added a `header`
slot to ResourceListPage for the one-time credentials banner; the tag-filter
chips go through `toolbarExtra`. Kept the custom loading skeleton and lite-tier
ResourceGate as early returns, and the Import/Create modals as children. All
behavior preserved (filter chips, search, tag filter, select-all + per-row
checkboxes, bulk ops, open/wp-admin links, row-click routing).
Verified: npm run build passes, 0 lint errors; WordPress list screenshot (mock
data) renders identically to before.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §6.4 (ResourceListPage) and
§6.2 (table → DataTable).
- Add components/layouts/ResourceListPage.jsx: the shared list-page chrome —
status-filter SegControl + search toolbar, bulk-actions bar, the DataTable, and
the loading / empty / filtered-empty states. Markup mirrors the existing
.wp-list design so SCSS applies unchanged.
- Services.jsx: replaced its hand-rolled .wp-list chrome + inline sk-dtable table
with ResourceListPage. The table is now DataTable columns; interactive cells
(checkbox, row actions) stop click propagation so they don't trigger the row
navigate. All behavior preserved (filter chips with counts, search, select-all
+ per-row checkboxes, bulk bar, source/status/env cells, row-click routing).
Verified: npm run build passes, 0 lint errors; Services screenshot (mock data)
renders identically to before (also fixed the section's stale wait-selector).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §7.3, following the Docker
split. Pure move-plus-imports refactors (no logic/JSX/state changes); the tabs
were already top-level + prop-driven, so the build validates every import.
- ServerDetail.jsx 2459 → 390 lines → components/serverdetail/ (serverDetailShared
+ ServerOverviewTab/AlertsTab/ServerDockerTab/CronTab/CloudflaredTab/
ServerMetricsTab/ServerSettingsTab; Server* prefixes avoid collisions with the
folder's existing PackagesTab/ServicesTab/SystemStatusCard).
- ApplicationDetail.jsx 1737 → 275 lines → new components/appdetail/ (appDetailShared
+ Overview/Packages/Gunicorn/Commands/Build/Logs/Settings/DeployTab).
- WordPressDetail.jsx 3992 → 464 lines → new components/wordpress/detail/
(wpDetailShared + 15 tab files; cross-tab modals re-exported, e.g. OverviewTab
imports CreateEnvironmentModal/SearchReplaceModal from their owning tabs).
Verified: combined npm run build passes, 0 lint errors; rendered all three detail
shells under Playwright (mock data) — header, full tab nav, and Overview content
render correctly (no pageerror/error-boundary). Combined with the build (which
resolves every tab import) this confirms the shell→tab wiring.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §7.3. Pure refactor (move +
imports only, no logic change). Docker.jsx goes from 2521 → 334 lines (a thin
shell: status/server/stats/tab state + layout). Extracted to components/docker/:
- dockerHelpers.js — ServerContext/useServer + the pure container helpers/constants
- dockerShared.jsx — IconAction, TrashIcon, ContainerResourceBars, DownloadIcon
- ContainersTab.jsx — ContainersTab + ContainerInspector + Run button/modal + logs/exec modals
- ComposeTab.jsx, ImagesTab.jsx, NetworksTab.jsx, VolumesTab.jsx, PruneButton.jsx
The tabs were already decoupled (shared ServerContext + onStatsChange prop, no
closures over the shell), so the split is mechanical.
Verified: npm run build passes, 0 lint errors, and drove ALL FIVE tabs
(Containers/Compose/Images/Networks/Volumes) open under Playwright with mock data
— each renders correctly (tables, status/port pills, resource bars, row actions,
toolbar buttons) identical to pre-split.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Converts the remaining hand-rolled .modal-overlay modals in the big pages to the
shared <Modal>: Docker (6: compose logs, run, exec, pull, create network/volume),
WordPressDetail (5: clone, search-replace, delete, create env, snapshot),
Domains (2: add domain, enable SSL), Servers (1: manage groups),
ApplicationDetail (2: build config, deploy config), WordPressProject (1: create
env). Same pattern: forms+actions in the body, sizes mapped, close-animation
null-guards where the body derefs open-state.
Only 2 .modal-overlay remain, both intentionally left — they are custom
right-side slide-in DRAWERS (Servers AddServerModal/.server-setup-modal and the
Templates detail panel) that need the Drawer primitive, not a centered Modal.
Verified: npm run build passes (each agent built independently + final combined
build).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §6.1. Converted the
.modal-overlay/.modal boilerplate to the shared Radix-backed <Modal> (focus
trap, Escape, backdrop, built-in close) across 20 files: AttachDomainModal,
ChangeUrlModal, ConfigDiffModal (xl), SettingsTab, Templates, WordPress (lg),
Workspaces, WorkspaceDetail, StatusPages, ServerTemplates, CloudProvision,
CronJobs, SSLCertificates, FTPServer, Email, FileManager, Git (lg/xl), Backups,
QueueDetail, QueueOperations. Forms keep their submit button + .modal-actions in
the Modal body; bodies that deref open-state objects are guarded for the close
animation; sizes mapped from old .modal-lg/.modal-xl.
Also hoisted .status-modal/.status-modal-grid out of .status-pages-page in
_status-pages.scss — the shared Modal portals to <body>, so page-scoped rules
would not have reached it.
Left intentionally: the Templates detail panel (custom slide-in drawer) and
ProjectDetail (already uses the Radix Dialog primitive directly).
Verified: npm run build passes; databases-modal pilot confirmed rendering via
Playwright; eslint adds no new errors.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §6.1 (priority #1 cluster).
Converted the 5 hand-rolled .modal-overlay modals in databases/modals.jsx
(CredentialsResult + Create MySQL/PostgreSQL Database/User) to the shared
components/Modal.jsx (Radix-backed: focus trap, Escape, backdrop). The form +
.modal-actions stay in the Modal body so the type=submit button remains inside
<form>. Logic unchanged.
Verified: npm run build passes; drove the Create MySQL database modal open under
Playwright (mock data) — renders correctly via .sk-modal.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §8.4. Replaced the hand-rolled
two-<button> role=tablist 'My Account / Admin' switch in Settings.jsx with the
shared components/ds/SegControl, so settings uses the same segmented-control
primitive as the rest of the app.
Verified: npm run build passes; settings screenshot confirms the segmented
control renders correctly.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Follow-up to the Sidebar XSS fix (c3eb51f) — the Sidebar customization preview
in SidebarSettings.jsx injected item.icon via dangerouslySetInnerHTML without
sanitizing. Routed it through sanitizeSvgInner like the main Sidebar. (The
SqlEditor and file-preview highlighters were checked and already escape-first,
so A5/A6 need no change.)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Follows the ConfirmProvider checkpoint. Removed the now-inert per-page
<ConfirmDialog> instances that were driven by useConfirm's confirmState across
18 files (ApplicationDetail, Docker, ServerDetail, Terminal, WordPressDetail,
Backups, CronJobs, Databases, Queue*, SSLCertificates, ServiceDetail,
ContainerOpsPanel, ProtectionPanel, BackupsTab, PreviewList, PackagesTab,
MigrationHistoryTab); simplified each useConfirm() destructure to { confirm } and
dropped the unused ConfirmDialog imports. confirm() now renders only via the
app-level provider.
~20 other files keep their own local-useState-controlled ConfirmDialogs (not
useConfirm-driven) — intentionally left; migrating those is a separate behavior
change.
Verified: npm run build passes; no dangling confirmState refs; Docker page
renders.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §6.6. Adds a single
app-level <ConfirmDialog> via ConfirmProvider (wraps the dashboard). useConfirm
is now context-aware: with the provider present, confirm() routes to the one
dialog and the legacy confirmState/handleConfirm/handleCancel become inert
no-ops (so the 39 pages' own <ConfirmDialog> render closed/harmless until
removed). Falls back to local state outside a provider so nothing breaks.
Backward-compatible checkpoint; the per-page dialog removal follows.
Verified: npm run build passes; 0 lint errors.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §8.5. React 18's automatic
JSX runtime makes 'import React' unnecessary; removed it from the 142 files
eslint flagged as 'React defined but never used' (named imports like useState
preserved). Driven by an eslint --format json pass so only flagged files were
touched.
Lint warnings: 1603 -> 1461 (0 errors). Verified: npm run build passes.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md §8.2 (A1/A8, A2).
- Sidebar icons were injected via dangerouslySetInnerHTML. Core icons are
trusted constants, but plugin-contributed nav items flow through the same path
and could supply arbitrary SVG. Added utils/sanitizeSvg.js: an allowlist
sanitizer (DOMParser-based, caches results) that keeps only safe SVG shape
elements/attributes and drops scripts/event handlers/external refs. Wired both
Sidebar icon sites through it — zero visual change (verified via screenshot).
- AI Alt+A shortcut: added a visible title tooltip + aria-keyshortcuts on the
chat bubble (discoverable), and made the global handler skippable via
localStorage 'sk_ai_shortcut' = 'off'.
Verified: npm run build passes; 0 lint errors; dashboard screenshot confirms
sidebar icons still render.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md. Two different components
were both named WafPanel.jsx (app-level vs Cloudflare-zone WAF), a real source
of confusion. Renamed:
- components/apps/WafPanel.jsx -> AppWafPanel.jsx
- components/cloudflare/WafPanel.jsx -> CloudflareWafPanel.jsx
Updated the single importer of each (ApplicationDetail, CloudflareZoneSettings).
Verified: npm run build passes; no stray WafPanel references remain.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md (acceptance: no
<div className="loading"> remains). Replaced all 14 ad-hoc loading divs across
13 files with the shared <EmptyState loading title="..." /> (centered spinner +
label), preserving each message verbatim. EmptyState was already imported in
Docker/Services; added the default import elsewhere.
Verified: npm run build passes; grep for className="loading" returns nothing;
eslint adds no new errors.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md. STATIC_PAGES had drifted
from the real route table:
- Drop the 'DNS Zones' /dns entry (it redirects to /domains); fold its
dns/records/nameserver/zones keywords into the Domains entry.
- Add the missing pages: Projects, Shared Variables, Workspaces, GPU Monitor,
Queue, Jobs, Telemetry, Secrets (all verified present in App.jsx).
Verified: npm run build passes.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md Phase 5.
- Add hooks/useLockBodyScroll.js: a ref-counted body-scroll lock that composes
nested locks correctly (a modal over an already-locked drawer no longer
restores scroll prematurely). Replaces the duplicated
document.body.style.overflow toggles in DashboardLayout (mobile nav drawer),
PreviewDrawer (file preview), and ChatDrawer (mobile AI sheet).
- lib/ai/markdown.js: escape quotes in link URLs. The renderer already
HTML-escapes all input and only emits allowlisted tags, but `"`/`'` in a
crafted URL could break out of the href attribute — now percent-encoded.
Verified: npm run build passes; eslint adds no new errors.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md Phase 4.
- pages/Applications.jsx: orphaned. /apps already redirects to /services and
/apps/:id renders ApplicationDetail; nothing imported this 481-line page.
- pages/Firewall.jsx: orphaned. /firewall already redirects to
/security/firewall; the live UI is components/security/FirewallTab.jsx.
- components/status/ContainerStatusPill.jsx: only consumed by dead Applications.
Kept _applications.scss and _firewall.scss — verified both are shared by live
components (ApplicationDetail/ServiceDetail/ContainerOpsPanel and FirewallTab),
so not orphaned. App.jsx route redirects retained so bookmarks don't 404.
Verified: npm run build passes; no remaining references to deleted files.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md Phase 3 utility consolidation.
Replaces the scattered, drifted-apart local helpers with the canonical utils
added in Phase 1.
formatBytes (was 14 local copies):
- utils/formatBytes.js realigned to the codebase convention (1024 divisor +
KB/MB/GB labels; `iec` opt switches labels to KiB/MiB). It was unused until
now, so displayed values are preserved.
- Removed local formatBytes/formatSize/formatMemory from ApplicationDetail,
Backups, Databases, Monitoring, Terminal, ServerDetail (x2), BackupsTab,
QuarantineTab, SystemTab, DiskUsageBar, SnapshotTable. Decimals matched per
call site (e.g. BackupsTab keeps 2 decimals); empty/falsy fallbacks preserved
via defaultValue. fileTypes.js and logHelpers.js now re-export the canonical
(their named exports are consumed elsewhere).
formatRelativeTime (was 6 local copies):
- ActivityFeed, PipelineView (x2), Dashboard migrated to utils/time.js.
- serviceTypes.js and logHelpers.js re-export the canonical.
- EnvironmentCard left as-is (intentionally distinct "Today/Yesterday/X days
ago" vocabulary, not the "Xm ago" format).
Behavioral deltas are cosmetic only: trailing-zero trim ("1.0 GB"->"1 GB"), the
date-fallback threshold normalized to 30d, and sub-hour times now show precise
"Xm ago". Units and numeric values are unchanged.
Verified: npm run build passes; eslint adds no new errors.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md Phase 2. Removes the Tailwind
CSS v4 dependency entirely; the internal SCSS design system is now the single
styling source (aligns with AGENTS.md / project policy).
Build wiring:
- Remove @tailwindcss/vite plugin from vite.config.js.
- Drop tailwindcss, @tailwindcss/vite, tailwind-merge, tailwindcss-animate from
package.json (+ lockfile).
- Delete src/globals.css and its import in main.jsx. --radius was already
redefined in _theme-variables.scss (loaded after globals), so nothing breaks;
repointed the 3 var(--color-primary) refs in _wordpress-pipeline.scss to
var(--accent-primary). Font stack now resolves to IBM Plex (SCSS) — the
Inter/JetBrains globals.css vars were unused.
- lib/utils.js: cn() now uses clsx only (no tailwind-merge).
Primitives (components/ui/*) converted to SCSS-only classes (.ui-*):
- dropdown-menu.jsx, command.jsx → new .ui-dropdown-* / .ui-command-* classes.
- skeleton.jsx → .ui-skeleton; popover.jsx → .ui-popover-panel.
- dialog/alert-dialog/select/sheet → dropped the tailwindcss-animate veneer;
enter/exit animation now handled by SCSS [data-state] keyframes in _ui.scss.
- alert-dialog AlertDialogAction gained a `variant` prop so non-danger confirms
keep their primary (not destructive) button.
- Modal.jsx → .sk-modal*; ConfirmDialog.jsx → .sk-confirm* (icon containers,
colors via theme tokens, layout) — the two heaviest raw-Tailwind components.
SCSS:
- _utilities.scss: extended the existing shim with a "Tailwind-removal
compatibility" layer covering every remaining utility class still referenced
in pages/components (positioning, sizing, spacing, semantic colors mapped to
theme tokens, sr-only, the handful of sm:/lg:/hover: variants actually used).
- _ui.scss: .ui-dropdown-*, .ui-command-*, .ui-skeleton, .ui-popover-panel,
.sk-modal*, .sk-confirm*, and [data-state] enter/exit animations.
Verified:
- npm run build passes; CSS shrank ~16kB (Tailwind utility layer gone).
- Completeness audit (scratchpad script): 0 un-styled Tailwind tokens remain
(only SCSS-nested BEM false positives).
- Visual smoke test (screenshots skill, mock data): dashboard / docker / servers
render correctly with full theming.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Per docs/plans/FRONTEND_UX_TAILWIND_CLEANUP_PLAN.md Phase 1:
- AGENTS.md: document the SCSS-only styling standard (forbid Tailwind/CSS-in-JS),
canonical primitives/utilities, and the in-progress Tailwind removal.
- ScheduleCard.jsx: fix Rules-of-Hooks violation (early return before
useState/useEffect/useMemo); hooks now run unconditionally before the loading
branch. Clears the 10 ESLint errors.
- Add canonical shared utilities to replace scattered duplicates:
utils/formatBytes.js, utils/time.js (timeAgo + formatRelativeTime),
utils/clipboard.js + hooks/useClipboard.js. timeAgo.js now re-exports time.js.
Verified: npm run build passes; eslint reports 0 errors in touched files.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Block stopping/restarting/removing ServerKit's own Docker containers and surface that in the UI. Backend: add DockerService helpers (is_protected_name / is_protected_container), route guard (_reject_if_protected) to reject destructive actions, annotate list_containers with a protected flag, and update cleanup logic. Add tests (backend/tests/test_docker_protection.py). Frontend: hide/replace lifecycle controls for protected containers (lock badge + styles), add Organization tab group (ORG_TABS) and migrate Projects/Shared Variables/Workspaces into a TabGroupLayout with topbar action hooks; update related styles and sidebar item matching.
serverkit update (update.sh) assumed the hybrid install shape (backend in a
host venv under systemd, frontend in Docker) and unconditionally ran
`source $INSTALL_DIR/venv/bin/activate`. On an all-Docker deployment (backend
AND frontend as compose services, no host venv) that crashes with
"venv/bin/activate: No such file or directory" -- and the preceding "stop
services" step leaves the box down with no restart.
Add is_docker_deployment() (compose file present + no host venv + a
serverkit-backend container exists) that routes to update_docker_compose():
in-place git sync, optional host frontend build when ./frontend/dist is
bind-mounted, `docker compose build` (the running version keeps serving until
the build succeeds), `up -d` (backend auto-migrates on boot), then a
container-health check. The hybrid venv/systemd/blue-green path is unchanged.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
A variable can now land on one compose service instead of all of them. Both
EnvironmentVariable and SharedVariable gain an optional target_service
(NULL = all services), threaded through the shared resolver as an inclusion
filter (a var applies to a service when it targets all OR that service).
EnvService.get_effective_env_for_services(app, services) computes each service's
merged env (all-services vars + that-service vars, local overriding shared), and
ComposeEnvService builds the override's per-service environment from it — so a
var targeted at "db" only appears under the db service, untargeted vars appear
everywhere. The single-container docker-run path is unchanged (one container
gets the full effective env regardless of target).
API: env-var create/update and shared-variable create/update accept
target_service; GET /apps/<id>/compose-services lists a compose app's services.
UI: the Environment tab shows an "Applies to" selector (gated to compose apps via
the service list) with a per-row target chip; the shared variable editor gains a
target-service field.
Migration 036 adds the two columns; single Alembic head; chain applies from
empty. Proving tests cover per-service distribution + the resolver helper. Full
backend suite: 949 passed, 14 skipped; frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Single-container apps already get the effective env via docker run -e. Compose
apps get container env from the compose file's environment:, so this wires them
the same way through a managed override compose file.
ComposeEnvService.refresh_for_project writes docker-compose.serverkit.yml next to
a managed app's base compose, adding an environment: overlay to every service
built from EnvService.get_effective_env (shared variable groups under the app's
own local env vars). Compose merges the override on top of the base, so the
effective env wins on collisions — consistent with the docker-run path. Dollar
signs are escaped ($ -> $$) so values survive compose interpolation intact.
DockerService.compose_up now includes the override as a second -f (via
_compose_cmd_with_overlay); `up -d` recreates changed containers so updated env
takes effect on the next deploy. It's non-destructive (ServerKit only owns the
override; the base compose is never edited), best-effort/guarded (a build failure
falls back to the plain base command and never blocks a deploy), regenerated each
up, and removed when the app has no effective env. Non-app dirs (e.g. proxy
stacks) and env-less apps are left untouched.
Proving test test_compose_env_overlay.py (6 cases): overlay injects shared+local
into every service with local winning collisions, $ escaping, stale-override
cleanup, non-app dirs untouched, and compose_up running with -f base -f override.
Full backend suite: 947 passed, 14 skipped.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Shared variable groups were resolved/displayed but never reached the container.
EnvService.get_effective_env(app) now merges them in: shared groups
(workspace < project < environment < direct) form the base layer and the app's
own local env vars override them, so a key set in both yields the local value —
matching the "Set locally — local value applies" UI hint. Secrets are decrypted
for injection; shared resolution is best-effort and never blocks a deploy.
The docker deploy path (_deploy_docker) now injects this merged env via
run_container, which also fixes a latent bug there (it called .get('success')
on get_env_vars()'s list result, so env was effectively never applied). Updated
the shared-variables panel note to say shared vars now apply at deploy with
local taking precedence.
Proving test test_effective_env.py (6 cases) covers the merge precedence, the
best-effort fallback, and that _deploy_docker hands run_container the merged env.
Full backend suite: 941 passed, 14 skipped; frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Tightens the seams the recent features introduced:
- Secret precedence/conflict: the embedded shared-variables panel now resolves
via the hierarchical endpoint, shows a per-variable source-scope badge +
precedence legend, and flags keys that are also set locally with a
"Set locally — local value applies" badge (shared groups are a facade and are
not injected into the container; the app's own env var is authoritative).
- Split inventory: apps now expose project_name/environment_name; the Services
list shows a project/environment badge (or "Unassigned") and a "Move to
project" bulk action (POST /apps/move-to-project, workspace-validated,
null-unassigns).
- Fleet proxy actionability: fleet_overview rows carry a {level,text}
recommendation (mismatch warning / idle stack / empty host / aligned),
rendered as a per-row pill.
- Onboarding wizard: "Step X of 5" + progress bar + rough ETA, and a
collapsible step-history trail so returning users get a clean summary.
- Config diff: a plain-language summary ("3 environment variables and the image
tag (app:1.2.1 -> app:1.1.9) changed") above the technical diff and echoed in
the restore confirmation.
- Container status: an always-visible "N issues" / "healthy/total" badge so a
degraded sub-container isn't hidden behind hover.
- Sidebar: Projects, Shared Variables and Workspaces collapse under a single
"Organization" group.
No schema change (project/environment names are derived). Backend suite: 935
passed, 14 skipped; frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Both reverse proxies bind 80/443, so pointing the same domain at host Nginx and
a Dockerized proxy stack is an operational footgun. This tags each app with the
plane it expects and surfaces disagreements instead of leaving them implicit.
- Each app carries an `ingress_plane` ('nginx' | 'proxy_stack'); NULL reads as
the host-Nginx default. New pure helpers in app/utils/ingress.py: only
container-based services are proxy-stack eligible, and a requested proxy_stack
is forced back to nginx for PHP/WordPress/static/Python apps. to_dict() also
exposes `ingress_proxy_eligible`.
- ProxyStackService.ingress_audit(server) reports which of a server's apps
disagree with its active proxy mode; fleet_overview now includes per-server
app_count + mismatch_count. New GET /servers/<id>/proxy/ingress-audit.
- Create wizard offers the proxy stack only for Docker/Compose services and
keeps the default on Nginx; app detail shows an Ingress badge; the fleet proxy
dashboard flags mismatch counts; the server proxy panel warns and lists the
specific mismatched apps with reasons.
Migration 035 adds applications.ingress_plane. Backend suite green (incl. 8 new
ingress tests); frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Server onboarding completion (C8): a pure pre-flight compatibility check
(arch/distro/kernel/cpu/memory) gating validate; real-but-guarded
distro-aware install_prerequisites/install_docker/pair_agent steps that
no-op safely on dev/Windows and never raise; audit + best-effort
notifications on each transition; and a live auto-scrolling log trail +
elapsed timer in the onboarding wizard.
- Fleet-wide proxy dashboard (C6): ProxyStackService.fleet_overview aggregates
every server's proxy posture (configured stack vs host Nginx default) behind
GET /api/v1/servers/proxy/overview, surfaced as a new Fleet Proxy page in the
Servers tab group with summary tiles + click-through to each server's proxy.
- Polymorphic shared resources depth (C9): hierarchical variable resolution
(workspace < project < environment < direct attachment < resource) with
source provenance and {{group.KEY}} interpolation, an audit trail on every
tag/group/variable/attachment mutation, GET /api/v1/shared/resolved/
hierarchical, and the reusable Tags/Environment-Variables panels embedded on
the application and server detail pages.
- Docs & coverage: docs/ENHANCEMENTS.md (brand-neutral guide to all ten
capabilities + verified endpoints), README/CHANGELOG updates, and a
cross-cutting integration test asserting the new endpoints are wired.
Full backend suite: 924 passed, 14 skipped; frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Project / Environment hierarchy (C2): Workspace -> Project -> Environment
org model. New Project/Environment models + CRUD APIs, nullable
applications.project_id/environment_id (opt-in, no destructive backfill),
ProjectService.ensure_default, a Projects list + ProjectDetail (env tabs),
a project/environment selector in the create wizard, and sidebar nav.
- Polymorphic shared resources facade (C9): ResourceTag + SharedVariableGroup
/SharedVariable/attachment models keyed by (resource_type, resource_id),
reusing the env-var Fernet encryption; SharedResourceService resolves merged
variables (most-recent attachment wins) with secrets masked. /api/v1/shared
endpoints + reusable TagsPanel/EnvironmentVariablesPanel + a Shared Variables
management page. Existing per-resource tables untouched (facade first).
- PR preview environments (C3): ApplicationPreview + settings models, a
PreviewService with pure domain-templating + reconcile (open PRs vs active
previews) cores and best-effort provisioning (incl. guarded WordPress
file+DB clone), a pull_request webhook endpoint, preview.* jobs, and a
Previews tab on the app detail page.
- Per-server managed proxy stack (C6): opt-in Dockerized Traefik/Caddy as a
Compose stack (host Nginx stays default and superior for PHP/WordPress).
ProxyStack model + ProxyStackService with pure compose/config generators and
versioned config backups, /api/v1/servers/<id>/proxy endpoints, and a Proxy
tab on the server detail page.
Migrations 031-034 add the new tables/columns; the full chain applies cleanly
from an empty DB. Full backend suite: 871 passed, 14 skipped; frontend builds.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Build packs / zero-Dockerfile deploys (C1): new BuildpackService detects the
stack from a cloned repo (Node/Python/Go/PHP/Ruby/Rust/static), produces a
transparent build plan and a generated Dockerfile, and persists the plan +
overrides on the Application. POST /api/v1/buildpacks/{detect,generate}; a
BuildpackPreview shows the detected plan + editable overrides + Dockerfile in
the create wizard and the app Build tab. Builds on the existing build_method
plumbing instead of duplicating it.
- Deployment config snapshots + diff engine (C4): ConfigurationService captures
an immutable, hashed snapshot of resolved config (env keys + masked values,
domains, image/tag, build method, volumes) at every deploy and rollback; new
DeploymentSnapshot model + /api/v1/apps/<id>/snapshots[/diff|/restore]. A
DeploymentTimeline + ConfigDiffModal surface "what changed" and one-click
restore in the app Deploy tab. Secret values are never serialized.
- Template catalog certification (C5 cont.): a whole-catalog validation test
proves all 105 declarative templates conform to the documented schema; fixed
the stale index.json (was 63/105 entries) to list every bundled template.
Migration 030 adds the buildpack columns + deployment_snapshots table. Full
backend suite: 820 passed, 14 skipped; frontend builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Four foundational enhancements toward the deploy-code developer experience:
- Container status aggregator (C7): new ContainerStatusService applies a
deterministic priority hierarchy (degraded > restarting > running:unhealthy >
starting > running:healthy > exited > unknown) over an app's containers,
cached with a short TTL. Exposed at /api/v1/status and pushed over a new
container_status Socket.IO channel; Applications page now renders an
aggregated ContainerStatusPill with sub-status tooltip.
- API token scopes + sensitive data masking (C10): require_scope() decorator
enforces fine-grained scopes for API-key requests (pass-through for JWT),
a canonical SCOPES catalog at /api/v1/api-keys/scopes, and a reusable
sensitive_data_filter (mask_sensitive) honoring secrets:read. Frontend gains
a grouped ApiKeyScopesModal picker and per-key scope pills.
- Server onboarding state machine (C8): new onboarding lifecycle
(pending -> validating -> installing_prerequisites -> installing_docker ->
pairing_agent -> ready/failed) with ServerOnboardingService, a
server_onboarding_logs table, servers.onboarding_* columns, REST endpoints,
and an OnboardingWizard surfaced on the server detail overview.
- Declarative template catalog (C5): documented catalog schema and
magic-variable resolution (SERVICE_PASSWORD_/USER_/FQDN_/URL_/BASE64_*)
layered onto the existing YAML template loader without changing behavior for
templates that don't use them; GET /api/v1/templates/catalog/schema.
Migration 029 adds the onboarding table + columns. 60 new tests pass; frontend
builds clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Introduce a ServerKit-managed per-site Fail2ban layer to protect WordPress login endpoints. Adds Fail2banJailService (write-side) to generate filter and per-site jail configs, enable/disable jails, reload fail2ban, and unban IPs (Linux-only, best-effort, ownership-guarded). Wire it into WordPress service lifecycle (enable on site create, remove on delete) and WpSecurityService wrapper methods. Expose API endpoints for status, toggle and unban in backend API. Add unit tests for Fail2banJailService (config rendering, naming/safety, lifecycle, graceful degradation). Frontend: Security tab loads brute-force status, can toggle protection, shows ban counts and unban action; API client and styles updated. NginxService gains canonical per-site log/error path helpers. Docs updated to reflect shipped brute-force jail feature.
Validates all 105 bundled templates parse + validate via the real TemplateService, ids match filenames, and every template has an icon; the 42 roadmap templates additionally use inline base64 icons, list-shaped vars, and are brand-neutral; and build_repo_index() covers the whole catalog. 149 cases, all green.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Makes the expanded catalog usable end-to-end:
- #24 Auto-domain: templates can opt in with 'auto_domain: true'; on install the app is published at <slug>.<base_domain> via the existing SiteDomainService (HTTPS only if the wildcard cert is already set up — never forces SSL; remote installs skipped).
- #25 Category consolidation: getCategoryIcon now covers the new tags (ai/llm/search/finance/documents/rss/vpn/dns/identity/observability/...).
- #26 Icon strategy: each template ships an inline lucide-style base64 icon with a keyed lucide fallback map; documented in Templates.jsx.
- #27 Update flow: update_app now normalizes list-format variables and re-renders the files: section + bind mounts, so converted/file-based templates (litellm, signoz, posthog) update correctly.
- #28 Community repo: TemplateService.build_repo_index()/export_repo_index() generate the index.json the sync mechanism already expects, exposed via GET /repos/index and POST /repos/index/export.
Roadmap: SERVICES_ROADMAP #24-#28.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds the AI/LLM one-click templates and wires the panel's own AI assistant to a self-hosted Prompture Hub:
- Templates: prompture-hub, ollama-webui, qdrant, chroma, litellm, flowise, langflow, anythingllm, librechat (brand-neutral, auto-port, generated secrets, lucide icons).
- AI provider: new 'prompture-hub' provider routed through Prompture's OpenAI-compatible cachibot driver (hub key + endpoint), so ServerKit AI can call a local hub instead of raw provider keys.
- Featured Prompture Hub + icon fallbacks in the Services UI.
Roadmap: SERVICES_ROADMAP #1-#8.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Introduce a full-screen AppLoader component and corresponding styles, and replace simple loading placeholders across App.jsx with the new loader. Revamp WordPressDetail: add comprehensive skeleton UI (topbar, repo pill, tab strip, KPI/panel/list/activity skeletons), generic PanelSkeleton and OverviewGridSkeleton utilities, and swap multiple tab-loading messages to use the new skeletons. Update layout and wordpress SCSS files to style the app-level loader and the WP detail skeletons. Improves perceived load UX and unifies loading states across the app.
The .ssl-status-* classes were borrowed "from _domains.scss", but that
borrow broke when Domains migrated to MetricCard - leaving the Certbot /
Certificates / Expiring Soon cards as an unstyled vertical stack at the
top-left. Define them locally in _ssl.scss as a 3-up grid of stat cards.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
/dns and /dynamic-dns duplicated the Domains portfolio + drawer and led
with a misleading "0 ServerKit records" view for Cloudflare zones.
Collapse DNS to one surface: both pages now redirect to /domains and
DomainDnsPanel becomes the full records manager.
- Per-record "Make dynamic" on A/AAAA rows (adopt-on-demand ->
createDdnsHost; one-time token via shared DdnsTokenCallout; Dynamic
badge + regenerate/stop)
- Export + Check propagation moved into the drawer; dead "Full DNS page"
button removed
- DOMAIN_TABS trimmed to Domains + SSL; /domains?open=<domain> deep-link
- Relocate shared .dns-rtype + .ddns-token-callout into _domains.scss
- Delete DNSZones.jsx, DynamicDns.jsx, _dns-zones.scss, _dynamic-dns.scss
Frontend-only; DDNS/portfolio backend untouched (20 tests green).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- /domains is one table: app-linked domains + live zones from connected DNS
providers (Cloudflare, ...) with provider badges. New GET /dns/portfolio
(aggregates provider zones, marks which are adopted) and idempotent
POST /dns/adopt (lazy-materialize a managed zone on demand).
- Every row opens one drawer = the unified DNS records surface
(components/domains/DomainDnsPanel): live Cloudflare records via
GET /dns/provider-records (no adopt needed), type badges, proxied=>HTTPS hint,
inline Add record, deep-links to Cloudflare ops / full DNS page. Fixed-layout
table (no horizontal scroll); actions moved into the drawer header.
- Registration expiry/registrar from Cloudflare Registrar + lazy RDAP fallback
(GET /dns/registration), persisted/cached in the new domain_registrations
table and merged into the portfolio so it survives a refresh. New
frontend/src/utils/expiry.js formatExpiry() date util.
- Connections moved to admin-only (Settings Admin group + isAdmin gate;
@admin_required on /api/v1/connections); CF connection card links to Domains.
- Cloudflare client: expose each zone's account_id; add list_registrar_domains.
- Tests: backend/tests/test_dns_portfolio.py.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>