coolify/resources/views/livewire/project/shared/execute-container-command.blade.php
rosslh ed49aed474
Some checks failed
Build MapleDeploy Coolify Image / build (push) Failing after 8s
feat(branding): apply MapleDeploy branding to Coolify
- Replace logos, colors (red/stone palette), and fonts (Overlock/Inter)
- Replace text logos with PNG from marketing API
- Update AGPL source links to match repo owner
- Update PostgreSQL to 17 for Alpine 3.23
- Add Forgejo Actions CI workflow
- Remove upstream GitHub Actions workflows
- Remove Coolify Cloud upsells, Hetzner provider, and telemetry
- Update auto-update to point to Forgejo registry
2026-02-11 21:22:39 -05:00

65 lines
3.3 KiB
PHP

<div>
<x-slot:title>
{{ data_get_str($resource, 'name')->limit(10) }} > Commands | MapleDeploy
</x-slot>
@if ($type === 'application')
<livewire:project.shared.configuration-checker :resource="$resource" />
<h1>Terminal</h1>
<livewire:project.application.heading :application="$resource" />
@elseif ($type === 'database')
<livewire:project.shared.configuration-checker :resource="$resource" />
<h1>Terminal</h1>
<livewire:project.database.heading :database="$resource" />
@elseif ($type === 'service')
<livewire:project.shared.configuration-checker :resource="$resource" />
<livewire:project.service.heading :service="$resource" :parameters="$parameters" title="Terminal" />
@endif
@if ($type === 'application' || $type === 'database' || $type === 'service')
<h2 class="pb-4">Terminal</h2>
@if (count($containers) === 0)
<div>No containers are running or terminal access is disabled on this server.</div>
@else
<form class="w-96 min-w-fit flex gap-2 items-end" wire:submit="$dispatchSelf('connectToContainer')"
x-data="{ autoConnected: false }" x-init="if ({{ count($containers) }} === 1 && !autoConnected) {
autoConnected = true;
$nextTick(() => $wire.dispatchSelf('connectToContainer'));
}">
<x-forms.select label="Container" id="container" required wire:model.live="selected_container">
@foreach ($containers as $container)
@if ($loop->first)
<option disabled value="default">Select a container</option>
@endif
<option value="{{ data_get($container, 'container.Names') }}">
{{ data_get($container, 'container.Names') }}
({{ data_get($container, 'server.name') }})
</option>
@endforeach
</x-forms.select>
<x-forms.button :disabled="$isConnecting"
type="submit">{{ $isConnecting ? 'Connecting...' : 'Connect' }}</x-forms.button>
</form>
<div class="mx-auto w-full">
<livewire:project.shared.terminal />
</div>
@endif
@endif
@if ($type === 'server')
<livewire:server.navbar :server="$servers->first()" />
@if ($servers->first()->isTerminalEnabled() && $servers->first()->isFunctional())
<form class="w-full flex gap-2 items-start" wire:submit="$dispatchSelf('connectToServer')"
x-data="{ autoConnected: false }"
x-on:terminal-websocket-ready.window="if (!autoConnected) { autoConnected = true; $wire.dispatchSelf('connectToServer'); }">
<h2 class="pb-4">Terminal</h2>
<x-forms.button :disabled="$isConnecting"
type="submit">{{ $isConnecting ? 'Connecting...' : 'Connect' }}</x-forms.button>
</form>
<div class="mx-auto w-full">
<livewire:project.shared.terminal />
</div>
@else
<div>Server is not functional or terminal access is disabled.</div>
@endif
@endif
</div>