34 lines
1.6 KiB
PHP
Raw Normal View History

2023-05-31 10:19:29 +02:00
<div>
@if ($isHeaderVisible)
<div>
<div class="flex items-center gap-2">
<h2>Storages</h2>
@if ($resource->type() !== 'service')
<x-helper
helper="For Preview Deployments, storage has a <span class='text-helper'>-pr-#PRNumber</span> in their
2023-06-05 12:07:55 +02:00
volume
2023-08-11 20:19:42 +02:00
name, example: <span class='text-helper'>-pr-1</span>" />
<x-forms.button class="btn" onclick="newStorage.showModal()">+ Add</x-forms.button>
<livewire:project.shared.storages.add :uuid="$resource->uuid" />
@endif
</div>
<div class="pb-4">Persistent storage to preserve data between deployments.</div>
@if ($resource->type() === 'service')
<span class="text-warning">Please modify storage layout in your <a class="underline"
href="{{ Str::of(url()->current())->beforeLast('/') }}">Docker Compose</a> file.</span>
<h2 class="pt-4">{{ Str::headline($resource->name) }} </h2>
2023-09-22 11:23:49 +02:00
@endif
2023-06-15 09:15:41 +02:00
</div>
@endif
<div class="flex flex-col gap-4">
@foreach ($resource->persistentStorages as $storage)
2023-09-22 11:23:49 +02:00
@if ($resource->type() === 'service')
<livewire:project.shared.storages.show wire:key="storage-{{ $storage->id }}" :storage="$storage" :isFirst="$loop->first"
2023-09-22 11:23:49 +02:00
isReadOnly='true' />
@else
<livewire:project.shared.storages.show wire:key="storage-{{ $storage->id }}" :storage="$storage" />
@endif
@endforeach
2023-05-31 10:19:29 +02:00
</div>
2023-05-05 12:08:38 +02:00
</div>