coolify/resources/views/components/applications/navbar.blade.php

79 lines
4.5 KiB
PHP
Raw Normal View History

2023-05-31 10:19:29 +02:00
<nav class="flex items-center gap-4 py-2 border-b-2 border-solid border-coolgray-200">
2023-05-22 15:47:40 +02:00
<a class="{{ request()->routeIs('project.application.configuration') ? 'text-white' : '' }}"
2023-05-09 09:54:43 +02:00
href="{{ route('project.application.configuration', [
'project_uuid' => Route::current()->parameters()['project_uuid'],
'application_uuid' => Route::current()->parameters()['application_uuid'],
'environment_name' => Route::current()->parameters()['environment_name'],
]) }}">
2023-05-22 22:30:33 +02:00
<button>Configuration</button>
2023-05-08 12:22:45 +02:00
</a>
2023-05-22 15:47:40 +02:00
<a class="{{ request()->routeIs('project.application.deployments') ? 'text-white' : '' }}"
2023-05-09 09:54:43 +02:00
href="{{ route('project.application.deployments', [
'project_uuid' => Route::current()->parameters()['project_uuid'],
'application_uuid' => Route::current()->parameters()['application_uuid'],
'environment_name' => Route::current()->parameters()['environment_name'],
]) }}">
2023-05-22 22:30:33 +02:00
<button>Deployments</button>
2023-05-16 20:47:59 +02:00
</a>
2023-05-18 15:19:23 +02:00
<div class="flex-1"></div>
2023-06-05 12:07:55 +02:00
<div class="dropdown dropdown-bottom dropdown-hover">
<label tabindex="0" class="flex items-center gap-2 text-sm cursor-pointer hover:text-white"> Links
<x-chevron-down />
2023-05-31 21:37:32 +02:00
</label>
2023-05-22 15:47:40 +02:00
<ul tabindex="0"
2023-06-05 12:07:55 +02:00
class="text-xs text-white normal-case rounded min-w-max dropdown-content menu bg-coolgray-200">
<li>
<a target="_blank" class="text-xs text-white rounded-none hover:no-underline hover:bg-coollabs"
href="{{ $application->gitBranchLocation }}">
<x-git-icon git="{{ $application->source->getMorphClass() }}" />
Git Repository
</a>
</li>
2023-05-26 10:20:09 +02:00
@if (data_get($application, 'fqdn'))
<li>
2023-06-02 12:34:45 +02:00
<a class="text-xs text-white rounded-none hover:no-underline hover:bg-coollabs" target="_blank"
2023-05-26 10:20:09 +02:00
href="{{ $application->fqdn }}">
2023-06-05 12:07:55 +02:00
<svg xmlns="http://www.w3.org/2000/svg" class="w-6 h-6" viewBox="0 0 24 24" stroke-width="1.5"
stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
<path d="M9 15l6 -6" />
<path d="M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464" />
<path
d="M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463" />
</svg>{{ $application->fqdn }}
2023-05-26 10:20:09 +02:00
</a>
</li>
@endif
2023-05-18 15:19:23 +02:00
@if (data_get($application, 'ports_mappings_array'))
@foreach ($application->ports_mappings_array as $port)
@if (config('app.env') === 'local')
<li>
2023-06-02 12:34:45 +02:00
<a class="text-xs text-white rounded-none hover:no-underline hover:bg-coollabs"
2023-06-05 12:07:55 +02:00
target="_blank" href="http://localhost:{{ explode(':', $port)[0] }}">
<svg xmlns="http://www.w3.org/2000/svg" class="w-6 h-6" viewBox="0 0 24 24"
stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round"
stroke-linejoin="round">
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
<path d="M9 15l6 -6" />
<path d="M11 6l.463 -.536a5 5 0 0 1 7.071 7.072l-.534 .464" />
<path
d="M13 18l-.397 .534a5.068 5.068 0 0 1 -7.127 0a4.972 4.972 0 0 1 0 -7.071l.524 -.463" />
</svg>{{ $port }}
2023-05-18 15:19:23 +02:00
</a>
</li>
@else
<li>
2023-05-26 10:20:09 +02:00
<a class="text-xs hover:no-underline hover:bg-coollabs" target="_blank"
href="http://{{ $application->destination->server->ip }}:{{ explode(':', $port)[0] }}">Port
2023-05-31 10:19:29 +02:00
{{ $port }}
</a>
2023-05-18 15:19:23 +02:00
</li>
@endif
@endforeach
2023-05-16 21:49:29 +02:00
@endif
2023-05-18 15:19:23 +02:00
</ul>
</div>
2023-05-22 15:47:40 +02:00
</div>
2023-05-16 21:49:29 +02:00
<livewire:project.application.deploy :applicationId="$application->id" />
2023-04-19 12:42:15 +02:00
</nav>