Merge pull request #1479 from coollabsio/next

v4.0.0-beta.146 - quick fix before release
This commit is contained in:
Andras Bacsai 2023-11-22 14:27:04 +01:00 committed by GitHub
commit 7f69eb3c2e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 8 deletions

View File

@ -23,7 +23,7 @@ class Advanced extends Component
];
public function instantSave()
{
if ($this->application->settings->is_log_drain_enabled) {
if ($this->application->isLogDrainEnabled()) {
if (!$this->application->destination->server->isLogDrainEnabled()) {
$this->application->settings->is_log_drain_enabled = false;
$this->emit('error', 'Log drain is not enabled on this server.');

View File

@ -28,7 +28,12 @@ public function instantSave()
}
public function instantSaveAdvanced()
{
$this->submit();
if (!$this->application->service->destination->server->isLogDrainEnabled()) {
$this->application->is_log_drain_enabled = false;
$this->emit('error', 'Log drain is not enabled on the server. Please enable it first.');
return;
}
$this->application->save();
$this->emit('success', 'You need to restart the service for the changes to take effect.');
}
public function delete()
@ -49,11 +54,6 @@ public function submit()
{
try {
$this->validate();
if (!$this->application->service->destination->server->isLogDrainEnabled()) {
$this->application->is_log_drain_enabled = false;
$this->emit('error', 'Log drain is not enabled on the server. Please enable it first.');
return;
}
$this->application->save();
updateCompose($this->application);
$this->emit('success', 'Application saved successfully.');

View File

@ -219,7 +219,7 @@ public function handle(): void
if ($this->server->isProxyShouldRun()) {
dispatch(new ContainerStatusJob($this->server));
}
if ($this->application->docker_registry_image_name) {
if ($this->application->docker_registry_image_name && $this->application->build_pack !== 'dockerimage') {
$this->push_to_docker_registry();
}
$this->next(ApplicationDeploymentStatus::FINISHED->value);