updates
This commit is contained in:
@@ -9,7 +9,7 @@ class ForceUpgrade extends Component
|
||||
{
|
||||
public function upgrade()
|
||||
{
|
||||
dispatch_sync(new InstanceAutoUpdateJob(force: true));
|
||||
$this->emit('updateInitiated');
|
||||
dispatch_sync(new InstanceAutoUpdateJob(force: true));
|
||||
}
|
||||
}
|
||||
|
||||
15
app/Http/Livewire/Upgrading.php
Normal file
15
app/Http/Livewire/Upgrading.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Livewire;
|
||||
|
||||
use Livewire\Component;
|
||||
|
||||
class Upgrading extends Component
|
||||
{
|
||||
public bool $visible = false;
|
||||
protected $listeners = ['updateInitiated'];
|
||||
public function updateInitiated()
|
||||
{
|
||||
$this->visible = true;
|
||||
}
|
||||
}
|
||||
@@ -65,16 +65,8 @@ class InstanceAutoUpdateJob implements ShouldQueue
|
||||
"sleep 10"
|
||||
], $this->server);
|
||||
} else {
|
||||
$cdn = "https://coolify-cdn.b-cdn.net/files";
|
||||
instant_remote_process([
|
||||
"curl -fsSL $cdn/docker-compose.yml -o /data/coolify/source/docker-compose.yml",
|
||||
"curl -fsSL $cdn/docker-compose.prod.yml -o /data/coolify/source/docker-compose.prod.yml",
|
||||
"curl -fsSL $cdn/.env.production -o /data/coolify/source/.env.production",
|
||||
"curl -fsSL $cdn/upgrade.sh -o /data/coolify/source/upgrade.sh",
|
||||
], $this->server);
|
||||
|
||||
instant_remote_process([
|
||||
"docker compose -f /data/coolify/source/docker-compose.yml -f /data/coolify/source/docker-compose.prod.yml pull",
|
||||
"curl -fsSL https://coolify-cdn.b-cdn.net/files/upgrade.sh -o /data/coolify/source/upgrade.sh",
|
||||
], $this->server);
|
||||
|
||||
remote_process([
|
||||
|
||||
Reference in New Issue
Block a user