commit
c37398af72
@ -20,7 +20,7 @@ public function handle(Service $service)
|
|||||||
$commands[] = "docker network inspect $service->uuid >/dev/null 2>&1 || docker network create --attachable $service->uuid";
|
$commands[] = "docker network inspect $service->uuid >/dev/null 2>&1 || docker network create --attachable $service->uuid";
|
||||||
$commands[] = 'echo Starting service.';
|
$commands[] = 'echo Starting service.';
|
||||||
$commands[] = "echo 'Pulling images.'";
|
$commands[] = "echo 'Pulling images.'";
|
||||||
$commands[] = 'docker compose pull --policy always';
|
$commands[] = 'docker compose pull';
|
||||||
$commands[] = "echo 'Starting containers.'";
|
$commands[] = "echo 'Starting containers.'";
|
||||||
$commands[] = 'docker compose up -d --remove-orphans --force-recreate --build';
|
$commands[] = 'docker compose up -d --remove-orphans --force-recreate --build';
|
||||||
$commands[] = "docker network connect $service->uuid coolify-proxy >/dev/null 2>&1 || true";
|
$commands[] = "docker network connect $service->uuid coolify-proxy >/dev/null 2>&1 || true";
|
||||||
|
@ -15,7 +15,7 @@ public function handle(Service $resource)
|
|||||||
|
|
||||||
$commands[] = 'cd '.$resource->workdir();
|
$commands[] = 'cd '.$resource->workdir();
|
||||||
$commands[] = "echo 'Saved configuration files to {$resource->workdir()}.'";
|
$commands[] = "echo 'Saved configuration files to {$resource->workdir()}.'";
|
||||||
$commands[] = 'docker compose pull --policy always';
|
$commands[] = 'docker compose pull';
|
||||||
|
|
||||||
$server = data_get($resource, 'server');
|
$server = data_get($resource, 'server');
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace App\Livewire\Tags;
|
namespace App\Livewire\Tags;
|
||||||
|
|
||||||
use App\Http\Controllers\Api\Deploy;
|
use App\Http\Controllers\Api\DeployController;
|
||||||
use App\Models\Tag;
|
use App\Models\Tag;
|
||||||
use Illuminate\Support\Collection;
|
use Illuminate\Support\Collection;
|
||||||
use Livewire\Attributes\Url;
|
use Livewire\Attributes\Url;
|
||||||
@ -51,11 +51,11 @@ public function redeploy_all()
|
|||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
$this->applications->each(function ($resource) {
|
$this->applications->each(function ($resource) {
|
||||||
$deploy = new Deploy();
|
$deploy = new DeployController();
|
||||||
$deploy->deploy_resource($resource);
|
$deploy->deploy_resource($resource);
|
||||||
});
|
});
|
||||||
$this->services->each(function ($resource) {
|
$this->services->each(function ($resource) {
|
||||||
$deploy = new Deploy();
|
$deploy = new DeployController();
|
||||||
$deploy->deploy_resource($resource);
|
$deploy->deploy_resource($resource);
|
||||||
});
|
});
|
||||||
$this->dispatch('success', 'Mass deployment started.');
|
$this->dispatch('success', 'Mass deployment started.');
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
namespace App\Livewire\Tags;
|
namespace App\Livewire\Tags;
|
||||||
|
|
||||||
use App\Http\Controllers\Api\Deploy;
|
use App\Http\Controllers\Api\DeployController;
|
||||||
use App\Models\ApplicationDeploymentQueue;
|
use App\Models\ApplicationDeploymentQueue;
|
||||||
use App\Models\Tag;
|
use App\Models\Tag;
|
||||||
use Livewire\Component;
|
use Livewire\Component;
|
||||||
@ -59,11 +59,11 @@ public function redeploy_all()
|
|||||||
try {
|
try {
|
||||||
$message = collect([]);
|
$message = collect([]);
|
||||||
$this->applications->each(function ($resource) use ($message) {
|
$this->applications->each(function ($resource) use ($message) {
|
||||||
$deploy = new Deploy();
|
$deploy = new DeployController();
|
||||||
$message->push($deploy->deploy_resource($resource));
|
$message->push($deploy->deploy_resource($resource));
|
||||||
});
|
});
|
||||||
$this->services->each(function ($resource) use ($message) {
|
$this->services->each(function ($resource) use ($message) {
|
||||||
$deploy = new Deploy();
|
$deploy = new DeployController();
|
||||||
$message->push($deploy->deploy_resource($resource));
|
$message->push($deploy->deploy_resource($resource));
|
||||||
});
|
});
|
||||||
$this->dispatch('success', 'Mass deployment started.');
|
$this->dispatch('success', 'Mass deployment started.');
|
||||||
|
@ -1688,7 +1688,7 @@ function parseDockerComposeFile(Service|Application $resource, bool $isNew = fal
|
|||||||
$read_only = data_get($volume, 'read_only');
|
$read_only = data_get($volume, 'read_only');
|
||||||
if ($source && $target) {
|
if ($source && $target) {
|
||||||
$uuid = $resource->uuid;
|
$uuid = $resource->uuid;
|
||||||
if ((str($source)->startsWith('.') || str($source)->startsWith('~'))) {
|
if ((str($source)->startsWith('.') || str($source)->startsWith('~') || str($source)->startsWith('/'))) {
|
||||||
$dir = base_configuration_dir().'/applications/'.$resource->uuid;
|
$dir = base_configuration_dir().'/applications/'.$resource->uuid;
|
||||||
if (str($source, '.')) {
|
if (str($source, '.')) {
|
||||||
$source = str($source)->replaceFirst('.', $dir);
|
$source = str($source)->replaceFirst('.', $dir);
|
||||||
@ -1696,11 +1696,6 @@ function parseDockerComposeFile(Service|Application $resource, bool $isNew = fal
|
|||||||
if (str($source, '~')) {
|
if (str($source, '~')) {
|
||||||
$source = str($source)->replaceFirst('~', $dir);
|
$source = str($source)->replaceFirst('~', $dir);
|
||||||
}
|
}
|
||||||
if ($pull_request_id === 0) {
|
|
||||||
$source = $uuid."-$source";
|
|
||||||
} else {
|
|
||||||
$source = $uuid."-$source-pr-$pull_request_id";
|
|
||||||
}
|
|
||||||
if ($read_only) {
|
if ($read_only) {
|
||||||
data_set($volume, 'source', $source.':'.$target.':ro');
|
data_set($volume, 'source', $source.':'.$target.':ro');
|
||||||
} else {
|
} else {
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
// The release version of your application
|
// The release version of your application
|
||||||
// Example with dynamic git hash: trim(exec('git --git-dir ' . base_path('.git') . ' log --pretty="%h" -n1 HEAD'))
|
// Example with dynamic git hash: trim(exec('git --git-dir ' . base_path('.git') . ' log --pretty="%h" -n1 HEAD'))
|
||||||
'release' => '4.0.0-beta.314',
|
'release' => '4.0.0-beta.315',
|
||||||
// When left empty or `null` the Laravel environment will be used
|
// When left empty or `null` the Laravel environment will be used
|
||||||
'environment' => config('app.env'),
|
'environment' => config('app.env'),
|
||||||
|
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
return '4.0.0-beta.314';
|
return '4.0.0-beta.315';
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"coolify": {
|
"coolify": {
|
||||||
"v4": {
|
"v4": {
|
||||||
"version": "4.0.0-beta.314"
|
"version": "4.0.0-beta.315"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user