fix: parser parser parser

This commit is contained in:
Andras Bacsai
2024-08-22 15:05:04 +02:00
parent cf505fa500
commit 1e24ab9146
7 changed files with 244 additions and 28 deletions

View File

@@ -472,7 +472,7 @@ class ApplicationDeploymentJob implements ShouldBeEncrypted, ShouldQueue
return;
}
$yaml = Yaml::dump($composeFile->toArray(), 10);
$yaml = Yaml::dump(convertToArray($composeFile), 10);
}
$this->docker_compose_base64 = base64_encode($yaml);
$this->execute_remote_command([
@@ -559,6 +559,7 @@ class ApplicationDeploymentJob implements ShouldBeEncrypted, ShouldQueue
$this->execute_remote_command(
[executeInDocker($this->deployment_uuid, $command), 'hidden' => true],
);
$this->write_deployment_configurations();
}
}

View File

@@ -204,7 +204,7 @@ class General extends Component
return;
}
$compose = $this->application->parseCompose();
$this->application->parseCompose();
$this->dispatch('success', 'Docker compose file loaded.');
$this->dispatch('compose_loaded');
$this->dispatch('refreshStorages');

View File

@@ -19,7 +19,7 @@ class Create extends Component
$destination_uuid = request()->query('destination');
$server_id = request()->query('server_id');
$database_image = request()->query('database_image');
ray($database_image);
$project = currentTeam()->load(['projects'])->projects->where('uuid', request()->route('project_uuid'))->first();
if (! $project) {
return redirect()->route('dashboard');

View File

@@ -1106,6 +1106,10 @@ class Application extends BaseModel
if (! $this->docker_compose_raw) {
return collect([]);
}
// $compose = dockerComposeParserForApplications($this);
// return $compose;
$isNew = false;
$isSameDockerComposeFile = false;