fix
This commit is contained in:
parent
43a4b1c9cb
commit
6910f9c5c7
@ -43,6 +43,7 @@ class Form extends Component
|
|||||||
if (!$this->server->settings->is_validated) {
|
if (!$this->server->settings->is_validated) {
|
||||||
$this->server->settings->is_validated = true;
|
$this->server->settings->is_validated = true;
|
||||||
$this->server->settings->save();
|
$this->server->settings->save();
|
||||||
|
$this->emit('serverValidated');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$this->dockerVersion = instantRemoteProcess(['docker version|head -2|grep -i version'], $this->server, false);
|
$this->dockerVersion = instantRemoteProcess(['docker version|head -2|grep -i version'], $this->server, false);
|
||||||
|
@ -11,11 +11,16 @@ use Livewire\Component;
|
|||||||
|
|
||||||
class Proxy extends Component
|
class Proxy extends Component
|
||||||
{
|
{
|
||||||
|
protected $listeners = ['serverValidated'];
|
||||||
public Server $server;
|
public Server $server;
|
||||||
|
|
||||||
public ProxyTypes $selectedProxy = ProxyTypes::TRAEFIK_V2;
|
public ProxyTypes $selectedProxy = ProxyTypes::TRAEFIK_V2;
|
||||||
public $proxy_settings = null;
|
public $proxy_settings = null;
|
||||||
|
|
||||||
|
public function serverValidated()
|
||||||
|
{
|
||||||
|
$this->server->settings->refresh();
|
||||||
|
}
|
||||||
public function installProxy()
|
public function installProxy()
|
||||||
{
|
{
|
||||||
$this->saveConfiguration($this->server);
|
$this->saveConfiguration($this->server);
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
<div>
|
<x-layout>
|
||||||
You are lost. <a href="{{ route('dashboard') }}">Go home</a>
|
<div class="flex items-center justify-center">
|
||||||
</div>
|
<div><a class="underline" href="{{ route('dashboard') }}">Go home</a></div>
|
||||||
|
</div>
|
||||||
|
</x-layout>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<div>
|
<div>
|
||||||
|
@if ($server->settings->is_validated)
|
||||||
@if ($this->server->extra_attributes->proxy_status !== 'running')
|
@if ($this->server->extra_attributes->proxy_status !== 'running')
|
||||||
<select wire:model="selectedProxy">
|
<select wire:model="selectedProxy">
|
||||||
<option value="{{ \App\Enums\ProxyTypes::TRAEFIK_V2 }}">
|
<option value="{{ \App\Enums\ProxyTypes::TRAEFIK_V2 }}">
|
||||||
@ -49,4 +49,8 @@
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
@else
|
||||||
|
<p>Server is not validated. Validate first.</p>
|
||||||
|
@endif
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -26,9 +26,5 @@
|
|||||||
<div>{{ $server->extra_attributes->proxy_status }}</div>
|
<div>{{ $server->extra_attributes->proxy_status }}</div>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
@if ($server->settings->is_validated)
|
|
||||||
<livewire:server.proxy :server="$server" />
|
<livewire:server.proxy :server="$server" />
|
||||||
@else
|
|
||||||
<p>Server is not validated. Validate first.</p>
|
|
||||||
@endif
|
|
||||||
</x-layout>
|
</x-layout>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user