Merge pull request #1274 from coollabsio/next

v4.0.0-beta.55
This commit is contained in:
Andras Bacsai 2023-10-01 17:40:31 +02:00 committed by GitHub
commit 1e0226c8ed
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 17 additions and 12 deletions

View File

@ -104,6 +104,7 @@ class General extends Component
}
public function mount()
{
if (data_get($this->application,'settings')) {
$this->is_static = $this->application->settings->is_static;
$this->is_git_submodules_enabled = $this->application->settings->is_git_submodules_enabled;
$this->is_git_lfs_enabled = $this->application->settings->is_git_lfs_enabled;
@ -112,6 +113,7 @@ class General extends Component
$this->is_auto_deploy_enabled = $this->application->settings->is_auto_deploy_enabled;
$this->is_force_https_enabled = $this->application->settings->is_force_https_enabled;
}
}
public function submit()
{

View File

@ -45,6 +45,9 @@ CMD ["nginx", "-g", "daemon off;"]
$environment = $project->load(['environments'])->environments->where('name', $this->parameters['environment_name'])->first();
$port = get_port_from_dockerfile($this->dockerfile);
if (!$port) {
$port = 80;
}
$application = Application::create([
'name' => 'dockerfile-' . new Cuid2(7),
'repository_project_id' => 0,

View File

@ -113,7 +113,7 @@ function generateApplicationContainerName(Application $application, $pull_reques
return $application->uuid . '-' . $now;
}
}
function get_port_from_dockerfile($dockerfile): int
function get_port_from_dockerfile($dockerfile): int|null
{
$dockerfile_array = explode("\n", $dockerfile);
$found_exposed_port = null;
@ -127,7 +127,7 @@ function get_port_from_dockerfile($dockerfile): int
if ($found_exposed_port) {
return (int)$found_exposed_port->value();
}
return 80;
return null;
}
function defaultLabels($id, $name, $pull_request_id = 0, string $type = 'application', $subType = null, $subId = null)

View File

@ -7,7 +7,7 @@ return [
// The release version of your application
// Example with dynamic git hash: trim(exec('git --git-dir ' . base_path('.git') . ' log --pretty="%h" -n1 HEAD'))
'release' => '4.0.0-beta.54',
'release' => '4.0.0-beta.55',
// When left empty or `null` the Laravel environment will be used
'environment' => config('app.env'),

View File

@ -1,3 +1,3 @@
<?php
return '4.0.0-beta.54';
return '4.0.0-beta.55';

View File

@ -4,7 +4,7 @@
"version": "3.12.36"
},
"v4": {
"version": "4.0.0-beta.54"
"version": "4.0.0-beta.55"
}
}
}