Commit graph

3356 commits

Author SHA1 Message Date
Andras Bacsai
db7d0f0bfb Merge remote-tracking branch 'origin/next' into feat/railpack 2026-05-11 16:26:50 +02:00
Andras Bacsai
d96e253230 fix(ui): align deployment indicator with collapsed sidebar
Move the deployments indicator inside the app layout state scope so it can react to the sidebar collapsed state, and add a layout test covering the responsive positioning.
2026-05-11 16:25:15 +02:00
Andras Bacsai
9f380b8495 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-05-11 10:58:13 +02:00
Andras Bacsai
8044045f13 fix(ui): replace border-l dirty indicator with box-shadow
Use inset box-shadow instead of left border to show unsaved env var
state, avoiding layout shift and border-radius interference.
2026-05-07 13:46:11 +02:00
Andras Bacsai
b623c9e5be fix(ui): move top padding to collapsed/expanded states in navbar
Padding `lg:pt-6` moved from static class to expanded-state Alpine binding,
and `lg:pt-8` added for collapsed state, so top spacing responds correctly
to sidebar collapse toggle.
2026-05-06 15:01:12 +02:00
Andras Bacsai
02dd8093a3 feat(ui): add collapsible sidebar with tooltip and team menu
Sidebar collapses to icon-only mode on lg breakpoint. State persists
in localStorage. Collapsed state shows logo icon, team initial button
with flyout menu, and hover tooltips for nav items.
2026-05-06 14:56:13 +02:00
Andras Bacsai
fe934dd139 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-05-06 14:33:22 +02:00
Andras Bacsai
d5e34c2249 Merge remote-tracking branch 'origin/next' into mcp-server-instance-toggle 2026-05-05 22:04:13 +02:00
Andras Bacsai
52f68c22ed Merge remote-tracking branch 'origin/next' into feat/railpack 2026-05-05 15:32:19 +02:00
Andras Bacsai
e89820b465 refactor(deployment): move copyLogs to client-side and hide refund when ineligible
Move copyLogs from PHP Livewire method to Alpine.js to avoid
unnecessary server round-trips. Extract collectVisibleLogs()
helper shared by both copy and download actions.

Hide refund section entirely when not eligible instead of
rendering a permanently disabled button.
2026-05-05 15:30:32 +02:00
Andras Bacsai
b6ca6b1b20 feat(railpack): expose COOLIFY_* vars at build time and generalize buildpack control flag
Mirrors Nixpacks behavior: inject COOLIFY_* and SOURCE_COMMIT into
railpack build variables so apps (e.g. SPAs baking public URLs) can
read them via /run/secrets/<KEY>.

Rename is_nixpacks → is_buildpack_control to cover both NIXPACKS_ and
RAILPACK_ prefixed keys. Update the env variable view and appends list
accordingly.

Promote generate_coolify_env_variables to protected for testability.
2026-04-30 18:31:41 +02:00
Andras Bacsai
7ab16ad7b5 feat(mcp): add MCP server with read-only tools for Coolify resources
Add Model Context Protocol server exposing Coolify infrastructure data
to AI assistants. Includes tools for listing/fetching servers, projects,
applications, databases, and services, scoped to authenticated team tokens.

- Add CoolifyServer with 10 read-only tools (list/get for all resource types)
- Add BuildsResponse and ResolvesTeam traits for shared tool logic
- Add EnsureMcpEnabled middleware guarding /mcp routes
- Add enable/disable MCP API endpoints (root-only)
- Add is_mcp_server_enabled toggle in instance settings and advanced UI
- Add migration for is_mcp_server_enabled column
- Add feature tests for MCP endpoints and toggle API
- Scrub sensitive keys (passwords, tokens, raw IDs) from all responses
2026-04-29 10:30:43 +02:00
Andras Bacsai
9717d9ff5a Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-29 08:56:23 +02:00
Andras Bacsai
eaaf258f25 fix(service): block UI editing of file volumes exceeding 5 MiB
Large host files mounted via Docker volumes caused the storages page to
become unusable — full file content was stored in the encrypted mediumText
column and serialised into the Livewire payload, crashing the browser.

- Add MAX_CONTENT_SIZE (5 MiB), BINARY_PLACEHOLDER, and TOO_LARGE_PLACEHOLDER
  constants to LocalFileVolume
- Check remote file size via stat/wc before cat in loadStorageOnServer and
  saveStorageOnServer; store placeholder instead of content when limit exceeded
- Expose is_too_large computed attribute (appended for Livewire serialisation)
- Guard submit, instantSave, and syncData in FileStorage Livewire component
- Truncate oversized content in Storage::refreshStorages to prevent payload bloat
- Show distinct warning banner in file-storage blade; mark textarea readonly and
  hide Save/Convert buttons for too-large files
- Add unit tests covering constants, computed flags, and toArray serialisation

Fixes #4701
2026-04-28 22:36:56 +02:00
Andras Bacsai
6293b14586 feat(server): add configurable SSH connection timeout per server
Add `connection_timeout` field to server settings, allowing per-server
override of the global SSH connection timeout constant.

- Migration adds `connection_timeout` integer column (default 10s)
- `ServerSetting` model exposes and casts the new field
- `SshMultiplexingHelper::getConnectionTimeout()` resolves per-server
  value with fallback to `constants.ssh.connection_timeout`
- All SSH/SCP command builders use the new resolver instead of the
  global config directly
- Livewire `Show` component binds `connectionTimeout` with validation
  (1–300 seconds) and syncs to/from the model
- UI input added to server settings form with helper text
- Feature tests cover default, persistence, resolver, and fallback
2026-04-28 15:39:36 +02:00
Andras Bacsai
5cef7cc092 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-28 14:36:54 +02:00
Andras Bacsai
268c97d18f
fix(validation): allow decimals for database backups max storage (#9801) 2026-04-28 12:33:00 +02:00
Andras Bacsai
1368026f20 fix(terminal): remove verbose websocket message logging 2026-04-28 12:29:32 +02:00
Andras Bacsai
cabcd8f699 fix(terminal): add idle timeout, reconnect replay, and scrollback preservation
- Kill PTY and notify client after 30 min of inactivity (IDLE_TIMEOUT_MS)
- Buffer client messages during async auth/IP fetch to prevent race-condition
  message loss on fast reconnects
- Replay last sent command after transient reconnect so PTY respawns without
  user interaction
- Preserve scrollback on disconnect/reconnect; write visible timestamp markers
  instead of wiping term state
- Handle idle-timeout sentinel on client with user-facing error message
2026-04-28 12:26:31 +02:00
Andras Bacsai
9408620d5f fix(terminal): add WS heartbeat and fix proxy idle disconnects
Proxies (Cloudflare, nginx) drop idle WebSocket connections before the
application notices, leaving clients typing into dead sockets.

- Add server-side ping/pong heartbeat (30s) in terminal-server.js;
  terminate unresponsive clients instead of letting connections go stale
- Move client keepAlive interval start to the connect event so it
  restarts correctly after reconnects
- Remove hidden-tab keepalive short-circuit — server pings now own
  liveness; suppressing client pings while hidden masked proxy drops
- Fix clearAllTimers to use clearTimeout for one-shot timers
- On visibility resume, probe with a 5s timeout instead of the default
  35s so half-open sockets are detected quickly
- Bump coolify-realtime to 1.0.14 across all compose files
2026-04-28 10:35:32 +02:00
Andras Bacsai
9a58e0fea2 fix(logs): disable auto-scroll on user scroll-up, re-enable on scroll-to-bottom
Add wheel, touch, and keyboard event handlers to log containers in
deployment and get-logs views. Auto-follow disables when user scrolls
up; re-enables when user scrolls back to bottom (within 10px threshold).
2026-04-28 10:33:08 +02:00
Andras Bacsai
9cd379e737 fix(helper): add Alpine.js click toggle to info helper popup
Replace CSS-only hover with Alpine.js click-based open/close,
including click.outside to dismiss.
2026-04-26 12:55:34 +02:00
ShadowArcanist
593006be88
fix(validation): allow decimals for database backups max storage 2026-04-25 22:27:26 +05:30
Andras Bacsai
90ddbb3572 feat(security): support expiration on API tokens with warning notifications
Add optional expiration to personal API tokens. Users pick a duration
(1/7/30/60/90 days or Never) at creation time. Expired tokens are
rejected by Sanctum, pruned hourly by sanctum:prune-expired, and a
team notification fires ~24h before expiry so owners can rotate
before API calls start failing.

- ApiTokens Livewire component stores expires_at from expiresInDays
- Rework issued-tokens UI from card grid to table (matches other views)
- New ApiTokenExpirationWarningJob scheduled hourly (idempotent via RateLimiter)
- New ApiTokenExpiringNotification (email/discord/telegram/slack/pushover)
- api_token_expiring added to alwaysSendEvents so users cannot silence
  expiry warnings from the per-event notification toggle UI
- sanctum:prune-expired cadence moved from daily to hourly

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-20 14:28:38 +02:00
Andras Bacsai
1002d211d0 style(database): wrap public port inputs in flex-col gap-2 container
Add wrapper div around publicPort and publicPortTimeout inputs across
all database general settings views for consistent vertical spacing.
2026-04-20 13:17:15 +02:00
peaklabs-dev
15cb9446ff
chore(swarm): mark docker swarm as deprecated 2026-04-17 23:41:39 +02:00
peaklabs-dev
340cd70ae5
chore(ui): add a deprecated notice component 2026-04-17 23:31:30 +02:00
Andras Bacsai
451b7376ed Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-17 07:01:27 +02:00
Andras Bacsai
68e8d6904d feat(env): add buildtime and runtime checkboxes for shared variables
Add is_buildtime and is_runtime checkboxes to shared environment
variable UI, shown in both editable and read-only (disabled) states.
2026-04-14 17:14:49 +02:00
Andras Bacsai
988c127e20 Merge remote-tracking branch 'origin/next' into domain-info-addition 2026-04-14 11:17:59 +02:00
Andras Bacsai
7196b05777 Merge remote-tracking branch 'origin/next' into domain-info-addition 2026-04-14 11:17:40 +02:00
Andras Bacsai
aa445b4a6c Resolve remaining merge conflicts 2026-04-14 11:14:22 +02:00
Andras Bacsai
07c6b02a82 Merge remote-tracking branch 'origin/next' into jean/organize-service-ui 2026-04-14 10:52:01 +02:00
Andras Bacsai
09f433b266
feat(ui): display memory limit fields in single row (#9232) 2026-04-14 10:39:37 +02:00
Andras Bacsai
f246e0aa99
feat(ui): add info callout to clone resource section about excluded items (#9233) 2026-04-14 10:39:00 +02:00
Andras Bacsai
340c5dc039
feat(ui): categorize application advanced settings into logical sections (#9234) 2026-04-14 10:38:43 +02:00
Andras Bacsai
0627db5342 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-10 12:20:09 +02:00
Andras Bacsai
0d8a95473a fix(ui): improve responsive project headings and controls
Refine mobile layout for project resource pages by making breadcrumbs and status blocks responsive, improving dropdown and checkbox touch behavior, and adding support for custom modal triggers. Add feature tests covering breadcrumb visibility and responsive checkbox layout.
2026-04-09 19:51:31 +02:00
Andras Bacsai
33f260a655 fix(deployments): use full-height deployment logs layout
Adjust the deployment view container classes so the logs panel fills the available viewport height instead of capping at 30rem. Add a feature test to lock in the full-height layout classes and prevent regressions.
2026-04-09 19:27:19 +02:00
Andras Bacsai
d7e1b7ec37 feat(railpack): add config merging, beta badge, and nodejs seeder example
- Implement railpack.json + generated config deep merging logic in
  ApplicationDeploymentJob with JSON validation and assoc array checks
- Label Railpack as "Beta" in all build pack selectors and show a
  visible beta badge when railpack is selected in new-app forms
- Add railpack-nodejs Fastify example to ApplicationSeeder
- Add ApplicationSeederTest and ApplicationDeploymentRailpackConfigTest
  covering config merge behavior and seeder correctness
2026-04-09 18:45:42 +02:00
Andras Bacsai
b1740cdc79 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-09 17:52:41 +02:00
Andras Bacsai
0649a424b8 fix(buildpack): revert default build pack to nixpacks and reorder selector
Change default build_pack from railpack back to nixpacks in all new
application flows (GithubPrivateRepository, GithubPrivateRepositoryDeployKey,
PublicGitRepository) and reorder the build pack dropdown so Nixpacks
appears before Railpack across all relevant views.

Add feature tests covering the nixpacks default and selector ordering.
2026-04-09 17:48:17 +02:00
Andras Bacsai
f573ad28a0 Merge remote-tracking branch 'origin/next' into feat/railpack 2026-04-09 17:12:26 +02:00
rosslh
17ba325924 fix(ui): make dashboard add buttons visible in light mode
The "+" icon buttons next to "Projects" and "Servers" headings used
text-white without a dark: prefix, making them invisible on light
backgrounds. Changed to text-black dark:text-white so the icon is
visible in both themes.

Fixes #9454
2026-04-06 15:09:54 -04:00
Andras Bacsai
968508583d fix(project): handle slash branches in public repo URLs
Parse `/tree/...` URLs by first capturing the full branch candidate, then
iteratively resolving valid branch names for GitHub API lookups and deriving
the remaining path as base directory. Also adjust env var editor/input view
classes (`font-sans`, `w-full`) and add/extend feature tests for both branch
parsing and multiline toggle rendering.
2026-04-01 09:11:56 +02:00
Andras Bacsai
3961077b90 feat(forms): make textarea monospace opt-in and improve multiline toggle
Add `monospace` prop to Textarea component so font-mono is no longer
applied by default. Apply it explicitly to env variable editors, private
key fields, and shared variable forms where monospace is appropriate.

Use Alpine.js x-data/x-model to make the multiline toggle reactive
without a full Livewire round-trip. Add wire:key on the input/textarea
wrappers to force proper DOM replacement when switching modes.
2026-03-31 15:37:42 +02:00
Andras Bacsai
4f6e1f7e42 style(navbar): use tracking-tight instead of tracking-wide for logo 2026-03-31 13:52:39 +02:00
Andras Bacsai
9c646b0a9e Merge remote-tracking branch 'origin/next' into pr-7764-shadow/add-shared-server-env 2026-03-31 13:51:06 +02:00
Andras Bacsai
7638912fdc fix(github): reset branch state when refreshing repositories
Clear `branches` and `total_branches_count` in `loadRepositories` to avoid stale branch data after repo refreshes. Update the Livewire view to use the shared loading button pattern for refresh/load actions, and expand feature coverage for repository refresh behavior and refresh button visibility.
2026-03-31 12:50:19 +02:00
Andras Bacsai
25c0c88eb2 Merge remote-tracking branch 'origin/next' into feat/refresh-repos 2026-03-31 12:37:38 +02:00