diff --git a/app/Actions/Server/UpdateCoolify.php b/app/Actions/Server/UpdateCoolify.php
index 3185c22b7..d57a4fe46 100644
--- a/app/Actions/Server/UpdateCoolify.php
+++ b/app/Actions/Server/UpdateCoolify.php
@@ -4,6 +4,7 @@ namespace App\Actions\Server;
use App\Jobs\PullHelperImageJob;
use App\Models\Server;
+use Illuminate\Support\Sleep;
use Lorisleiva\Actions\Concerns\AsAction;
class UpdateCoolify
@@ -18,6 +19,11 @@ class UpdateCoolify
public function handle($manual_update = false)
{
+ if (isDev()) {
+ Sleep::for(10)->seconds();
+
+ return;
+ }
$settings = instanceSettings();
$this->server = Server::find(0);
if (! $this->server) {
@@ -44,19 +50,7 @@ class UpdateCoolify
private function update()
{
- if (isDev()) {
- remote_process([
- 'sleep 10',
- ], $this->server);
-
- return;
- }
-
- $all_servers = Server::all();
- $servers = $all_servers->where('settings.is_usable', true)->where('settings.is_reachable', true)->where('ip', '!=', '1.2.3.4');
- foreach ($servers as $server) {
- PullHelperImageJob::dispatch($server);
- }
+ PullHelperImageJob::dispatch($this->server);
instant_remote_process(["docker pull -q ghcr.io/coollabsio/coolify:{$this->latestVersion}"], $this->server, false);
diff --git a/app/Http/Controllers/Api/ApplicationsController.php b/app/Http/Controllers/Api/ApplicationsController.php
index f0eeb56d8..500db3922 100644
--- a/app/Http/Controllers/Api/ApplicationsController.php
+++ b/app/Http/Controllers/Api/ApplicationsController.php
@@ -636,7 +636,7 @@ class ApplicationsController extends Controller
private function create_application(Request $request, $type)
{
- $allowedFields = ['project_uuid', 'environment_name', 'server_uuid', 'destination_uuid', 'type', 'name', 'description', 'is_static', 'domains', 'git_repository', 'git_branch', 'git_commit_sha', 'private_key_uuid', 'docker_registry_image_name', 'docker_registry_image_tag', 'build_pack', 'install_command', 'build_command', 'start_command', 'ports_exposes', 'ports_mappings', 'base_directory', 'publish_directory', 'health_check_enabled', 'health_check_path', 'health_check_port', 'health_check_host', 'health_check_method', 'health_check_return_code', 'health_check_scheme', 'health_check_response_text', 'health_check_interval', 'health_check_timeout', 'health_check_retries', 'health_check_start_period', 'limits_memory', 'limits_memory_swap', 'limits_memory_swappiness', 'limits_memory_reservation', 'limits_cpus', 'limits_cpuset', 'limits_cpu_shares', 'custom_labels', 'custom_docker_run_options', 'post_deployment_command', 'post_deployment_command_container', 'pre_deployment_command', 'pre_deployment_command_container', 'manual_webhook_secret_github', 'manual_webhook_secret_gitlab', 'manual_webhook_secret_bitbucket', 'manual_webhook_secret_gitea', 'redirect', 'github_app_uuid', 'instant_deploy', 'dockerfile', 'docker_compose_location', 'docker_compose_raw', 'docker_compose_custom_start_command', 'docker_compose_custom_build_command', 'docker_compose_domains', 'watch_paths', 'use_build_server', 'static_image'];
+ $allowedFields = ['project_uuid', 'environment_name', 'server_uuid', 'destination_uuid', 'type', 'name', 'description', 'is_static', 'domains', 'git_repository', 'git_branch', 'git_commit_sha', 'private_key_uuid', 'docker_registry_image_name', 'docker_registry_image_tag', 'build_pack', 'install_command', 'build_command', 'start_command', 'ports_exposes', 'ports_mappings', 'base_directory', 'publish_directory', 'health_check_enabled', 'health_check_path', 'health_check_port', 'health_check_host', 'health_check_method', 'health_check_return_code', 'health_check_scheme', 'health_check_response_text', 'health_check_interval', 'health_check_timeout', 'health_check_retries', 'health_check_start_period', 'limits_memory', 'limits_memory_swap', 'limits_memory_swappiness', 'limits_memory_reservation', 'limits_cpus', 'limits_cpuset', 'limits_cpu_shares', 'custom_labels', 'custom_docker_run_options', 'post_deployment_command', 'post_deployment_command_container', 'pre_deployment_command', 'pre_deployment_command_container', 'manual_webhook_secret_github', 'manual_webhook_secret_gitlab', 'manual_webhook_secret_bitbucket', 'manual_webhook_secret_gitea', 'redirect', 'github_app_uuid', 'instant_deploy', 'dockerfile', 'docker_compose_location', 'docker_compose_raw', 'docker_compose_custom_start_command', 'docker_compose_custom_build_command', 'docker_compose_domains', 'watch_paths', 'use_build_server', 'static_image', 'custom_nginx_configuration'];
$teamId = getTeamIdFromToken();
if (is_null($teamId)) {
return invalidTokenResponse();
@@ -676,6 +676,27 @@ class ApplicationsController extends Controller
$githubAppUuid = $request->github_app_uuid;
$useBuildServer = $request->use_build_server;
$isStatic = $request->is_static;
+ $customNginxConfiguration = $request->custom_nginx_configuration;
+
+ if (! is_null($customNginxConfiguration)) {
+ if (! isBase64Encoded($customNginxConfiguration)) {
+ return response()->json([
+ 'message' => 'Validation failed.',
+ 'errors' => [
+ 'custom_nginx_configuration' => 'The custom_nginx_configuration should be base64 encoded.',
+ ],
+ ], 422);
+ }
+ $customNginxConfiguration = base64_decode($customNginxConfiguration);
+ if (mb_detect_encoding($customNginxConfiguration, 'ASCII', true) === false) {
+ return response()->json([
+ 'message' => 'Validation failed.',
+ 'errors' => [
+ 'custom_nginx_configuration' => 'The custom_nginx_configuration should be base64 encoded.',
+ ],
+ ], 422);
+ }
+ }
$project = Project::whereTeamId($teamId)->whereUuid($request->project_uuid)->first();
if (! $project) {
@@ -1500,7 +1521,7 @@ class ApplicationsController extends Controller
], 404);
}
$server = $application->destination->server;
- $allowedFields = ['name', 'description', 'is_static', 'domains', 'git_repository', 'git_branch', 'git_commit_sha', 'docker_registry_image_name', 'docker_registry_image_tag', 'build_pack', 'static_image', 'install_command', 'build_command', 'start_command', 'ports_exposes', 'ports_mappings', 'base_directory', 'publish_directory', 'health_check_enabled', 'health_check_path', 'health_check_port', 'health_check_host', 'health_check_method', 'health_check_return_code', 'health_check_scheme', 'health_check_response_text', 'health_check_interval', 'health_check_timeout', 'health_check_retries', 'health_check_start_period', 'limits_memory', 'limits_memory_swap', 'limits_memory_swappiness', 'limits_memory_reservation', 'limits_cpus', 'limits_cpuset', 'limits_cpu_shares', 'custom_labels', 'custom_docker_run_options', 'post_deployment_command', 'post_deployment_command_container', 'pre_deployment_command', 'pre_deployment_command_container', 'watch_paths', 'manual_webhook_secret_github', 'manual_webhook_secret_gitlab', 'manual_webhook_secret_bitbucket', 'manual_webhook_secret_gitea', 'docker_compose_location', 'docker_compose_raw', 'docker_compose_custom_start_command', 'docker_compose_custom_build_command', 'docker_compose_domains', 'redirect', 'instant_deploy', 'use_build_server'];
+ $allowedFields = ['name', 'description', 'is_static', 'domains', 'git_repository', 'git_branch', 'git_commit_sha', 'docker_registry_image_name', 'docker_registry_image_tag', 'build_pack', 'static_image', 'install_command', 'build_command', 'start_command', 'ports_exposes', 'ports_mappings', 'base_directory', 'publish_directory', 'health_check_enabled', 'health_check_path', 'health_check_port', 'health_check_host', 'health_check_method', 'health_check_return_code', 'health_check_scheme', 'health_check_response_text', 'health_check_interval', 'health_check_timeout', 'health_check_retries', 'health_check_start_period', 'limits_memory', 'limits_memory_swap', 'limits_memory_swappiness', 'limits_memory_reservation', 'limits_cpus', 'limits_cpuset', 'limits_cpu_shares', 'custom_labels', 'custom_docker_run_options', 'post_deployment_command', 'post_deployment_command_container', 'pre_deployment_command', 'pre_deployment_command_container', 'watch_paths', 'manual_webhook_secret_github', 'manual_webhook_secret_gitlab', 'manual_webhook_secret_bitbucket', 'manual_webhook_secret_gitea', 'docker_compose_location', 'docker_compose_raw', 'docker_compose_custom_start_command', 'docker_compose_custom_build_command', 'docker_compose_domains', 'redirect', 'instant_deploy', 'use_build_server', 'custom_nginx_configuration'];
$validationRules = [
'name' => 'string|max:255',
@@ -1512,6 +1533,7 @@ class ApplicationsController extends Controller
'docker_compose_domains' => 'array|nullable',
'docker_compose_custom_start_command' => 'string|nullable',
'docker_compose_custom_build_command' => 'string|nullable',
+ 'custom_nginx_configuration' => 'string|nullable',
];
$validationRules = array_merge($validationRules, sharedDataApplications());
$validator = customApiValidator($request->all(), $validationRules);
@@ -1530,6 +1552,25 @@ class ApplicationsController extends Controller
}
}
}
+ if ($request->has('custom_nginx_configuration')) {
+ if (! isBase64Encoded($request->custom_nginx_configuration)) {
+ return response()->json([
+ 'message' => 'Validation failed.',
+ 'errors' => [
+ 'custom_nginx_configuration' => 'The custom_nginx_configuration should be base64 encoded.',
+ ],
+ ], 422);
+ }
+ $customNginxConfiguration = base64_decode($request->custom_nginx_configuration);
+ if (mb_detect_encoding($customNginxConfiguration, 'ASCII', true) === false) {
+ return response()->json([
+ 'message' => 'Validation failed.',
+ 'errors' => [
+ 'custom_nginx_configuration' => 'The custom_nginx_configuration should be base64 encoded.',
+ ],
+ ], 422);
+ }
+ }
$return = $this->validateDataApplications($request, $server);
if ($return instanceof \Illuminate\Http\JsonResponse) {
return $return;
diff --git a/app/Jobs/ApplicationDeploymentJob.php b/app/Jobs/ApplicationDeploymentJob.php
index 5ceed332a..27eded4f3 100644
--- a/app/Jobs/ApplicationDeploymentJob.php
+++ b/app/Jobs/ApplicationDeploymentJob.php
@@ -1990,22 +1990,11 @@ COPY . .
RUN rm -f /usr/share/nginx/html/nginx.conf
RUN rm -f /usr/share/nginx/html/Dockerfile
COPY ./nginx.conf /etc/nginx/conf.d/default.conf");
- $nginx_config = base64_encode('server {
- listen 80;
- listen [::]:80;
- server_name localhost;
-
- location / {
- root /usr/share/nginx/html;
- index index.html;
- try_files $uri $uri.html $uri/index.html $uri/ /index.html =404;
+ if (str($this->application->custom_nginx_configuration)->isNotEmpty()) {
+ $nginx_config = base64_encode($this->application->custom_nginx_configuration);
+ } else {
+ $nginx_config = base64_encode(defaultNginxConfiguration());
}
-
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- root /usr/share/nginx/html;
- }
- }');
} else {
if ($this->application->build_pack === 'nixpacks') {
$this->nixpacks_plan = base64_encode($this->nixpacks_plan);
@@ -2068,23 +2057,11 @@ WORKDIR /usr/share/nginx/html/
LABEL coolify.deploymentId={$this->deployment_uuid}
COPY --from=$this->build_image_name /app/{$this->application->publish_directory} .
COPY ./nginx.conf /etc/nginx/conf.d/default.conf");
-
- $nginx_config = base64_encode('server {
- listen 80;
- listen [::]:80;
- server_name localhost;
-
- location / {
- root /usr/share/nginx/html;
- index index.html;
- try_files $uri $uri.html $uri/index.html $uri/ /index.html =404;
+ if (str($this->application->custom_nginx_configuration)->isNotEmpty()) {
+ $nginx_config = base64_encode($this->application->custom_nginx_configuration);
+ } else {
+ $nginx_config = base64_encode(defaultNginxConfiguration());
}
-
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- root /usr/share/nginx/html;
- }
- }');
}
$build_command = "docker build {$this->addHosts} --network host -f {$this->workdir}/Dockerfile {$this->build_args} --progress plain -t {$this->production_image_name} {$this->workdir}";
$base64_build_command = base64_encode($build_command);
diff --git a/app/Livewire/Project/Application/General.php b/app/Livewire/Project/Application/General.php
index f1575a01f..ff29b74e9 100644
--- a/app/Livewire/Project/Application/General.php
+++ b/app/Livewire/Project/Application/General.php
@@ -84,6 +84,7 @@ class General extends Component
'application.pre_deployment_command_container' => 'nullable',
'application.post_deployment_command' => 'nullable',
'application.post_deployment_command_container' => 'nullable',
+ 'application.custom_nginx_configuration' => 'nullable',
'application.settings.is_static' => 'boolean|required',
'application.settings.is_build_server_enabled' => 'boolean|required',
'application.settings.is_container_label_escape_enabled' => 'boolean|required',
@@ -121,6 +122,7 @@ class General extends Component
'application.custom_docker_run_options' => 'Custom docker run commands',
'application.docker_compose_custom_start_command' => 'Docker compose custom start command',
'application.docker_compose_custom_build_command' => 'Docker compose custom build command',
+ 'application.custom_nginx_configuration' => 'Custom Nginx configuration',
'application.settings.is_static' => 'Is static',
'application.settings.is_build_server_enabled' => 'Is build server enabled',
'application.settings.is_container_label_escape_enabled' => 'Is container label escape enabled',
@@ -241,6 +243,13 @@ class General extends Component
}
}
+ public function updatedApplicationSettingsIsStatic($value)
+ {
+ if ($value) {
+ $this->generateNginxConfiguration();
+ }
+ }
+
public function updatedApplicationBuildPack()
{
if ($this->application->build_pack !== 'nixpacks') {
@@ -257,6 +266,7 @@ class General extends Component
if ($this->application->build_pack === 'static') {
$this->application->ports_exposes = $this->ports_exposes = 80;
$this->resetDefaultLabels(false);
+ $this->generateNginxConfiguration();
}
$this->submit();
$this->dispatch('buildPackUpdated');
@@ -274,6 +284,13 @@ class General extends Component
}
}
+ public function generateNginxConfiguration()
+ {
+ $this->application->custom_nginx_configuration = defaultNginxConfiguration();
+ $this->application->save();
+ $this->dispatch('success', 'Nginx configuration generated.');
+ }
+
public function resetDefaultLabels($manualReset = false)
{
try {
diff --git a/app/Livewire/Upgrade.php b/app/Livewire/Upgrade.php
index 88ed88cb7..e50085c64 100644
--- a/app/Livewire/Upgrade.php
+++ b/app/Livewire/Upgrade.php
@@ -23,6 +23,9 @@ class Upgrade extends Component
try {
$this->latestVersion = get_latest_version_of_coolify();
$this->isUpgradeAvailable = data_get(InstanceSettings::get(), 'new_version_available', false);
+ if (isDev()) {
+ $this->isUpgradeAvailable = true;
+ }
} catch (\Throwable $e) {
return handleError($e, $this);
}
diff --git a/app/Models/Application.php b/app/Models/Application.php
index 0ef787b2e..64244c900 100644
--- a/app/Models/Application.php
+++ b/app/Models/Application.php
@@ -98,6 +98,7 @@ use Visus\Cuid2\Cuid2;
'updated_at' => ['type' => 'string', 'format' => 'date-time', 'description' => 'The date and time when the application was last updated.'],
'deleted_at' => ['type' => 'string', 'format' => 'date-time', 'nullable' => true, 'description' => 'The date and time when the application was deleted.'],
'compose_parsing_version' => ['type' => 'string', 'description' => 'How Coolify parse the compose file.'],
+ 'custom_nginx_configuration' => ['type' => 'string', 'nullable' => true, 'description' => 'Custom Nginx configuration base64 encoded.'],
]
)]
@@ -114,11 +115,11 @@ class Application extends BaseModel
protected static function booted()
{
static::saving(function ($application) {
- if ($application->fqdn === '') {
- $application->fqdn = null;
- }
$payload = [];
if ($application->isDirty('fqdn')) {
+ if ($application->fqdn === '') {
+ $application->fqdn = null;
+ }
$payload['fqdn'] = $application->fqdn;
}
if ($application->isDirty('install_command')) {
@@ -139,6 +140,11 @@ class Application extends BaseModel
if ($application->isDirty('status')) {
$payload['last_online_at'] = now();
}
+ if ($application->isDirty('custom_nginx_configuration')) {
+ if ($application->custom_nginx_configuration === '') {
+ $payload['custom_nginx_configuration'] = null;
+ }
+ }
if (count($payload) > 0) {
$application->forceFill($payload);
}
@@ -632,6 +638,14 @@ class Application extends BaseModel
);
}
+ public function customNginxConfiguration(): Attribute
+ {
+ return Attribute::make(
+ set: fn ($value) => base64_encode($value),
+ get: fn ($value) => base64_decode($value),
+ );
+ }
+
public function portsExposesArray(): Attribute
{
return Attribute::make(
@@ -862,7 +876,7 @@ class Application extends BaseModel
public function isConfigurationChanged(bool $save = false)
{
- $newConfigHash = $this->fqdn.$this->git_repository.$this->git_branch.$this->git_commit_sha.$this->build_pack.$this->static_image.$this->install_command.$this->build_command.$this->start_command.$this->ports_exposes.$this->ports_mappings.$this->base_directory.$this->publish_directory.$this->dockerfile.$this->dockerfile_location.$this->custom_labels.$this->custom_docker_run_options.$this->dockerfile_target_build.$this->redirect;
+ $newConfigHash = base64_encode($this->fqdn.$this->git_repository.$this->git_branch.$this->git_commit_sha.$this->build_pack.$this->static_image.$this->install_command.$this->build_command.$this->start_command.$this->ports_exposes.$this->ports_mappings.$this->base_directory.$this->publish_directory.$this->dockerfile.$this->dockerfile_location.$this->custom_labels.$this->custom_docker_run_options.$this->dockerfile_target_build.$this->redirect.$this->custom_nginx_configuration);
if ($this->pull_request_id === 0 || $this->pull_request_id === null) {
$newConfigHash .= json_encode($this->environment_variables()->get('value')->sort());
} else {
diff --git a/app/Models/Server.php b/app/Models/Server.php
index 3076308ad..64192c71f 100644
--- a/app/Models/Server.php
+++ b/app/Models/Server.php
@@ -64,7 +64,7 @@ class Server extends BaseModel
$server->forceFill($payload);
});
static::saved(function ($server) {
- if ($server->privateKey->isDirty()) {
+ if ($server->privateKey?->isDirty()) {
refresh_server_connection($server->privateKey);
}
});
diff --git a/bootstrap/helpers/shared.php b/bootstrap/helpers/shared.php
index f6875cc81..2f0a3ac2a 100644
--- a/bootstrap/helpers/shared.php
+++ b/bootstrap/helpers/shared.php
@@ -4062,3 +4062,33 @@ function isEmailRateLimited(string $limiterKey, int $decaySeconds = 3600, ?calla
return $rateLimited;
}
+
+function defaultNginxConfiguration(): string
+{
+ return 'server {
+ location / {
+ root /usr/share/nginx/html;
+ index index.html index.htm;
+ try_files $uri $uri/index.html =404;
+ }
+
+ error_page 500 502 503 504 /50x.html;
+ location = /50x.html {
+ root /usr/share/nginx/html;
+ try_files $uri @redirect_to_index;
+ internal;
+ }
+
+ error_page 404 = @handle_404;
+
+ location @handle_404 {
+ root /usr/share/nginx/html;
+ try_files /404.html @redirect_to_index;
+ internal;
+ }
+
+ location @redirect_to_index {
+ return 302 /;
+ }
+}';
+}
diff --git a/config/sentry.php b/config/sentry.php
index 97488c6dd..117a0e6d8 100644
--- a/config/sentry.php
+++ b/config/sentry.php
@@ -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.364',
+ 'release' => '4.0.0-beta.367',
// When left empty or `null` the Laravel environment will be used
'environment' => config('app.env'),
diff --git a/config/subscription.php b/config/subscription.php
index 3e0182de9..a033862d2 100644
--- a/config/subscription.php
+++ b/config/subscription.php
@@ -6,21 +6,7 @@ return [
// Stripe
'stripe_api_key' => env('STRIPE_API_KEY', null),
'stripe_webhook_secret' => env('STRIPE_WEBHOOK_SECRET', null),
- 'stripe_price_id_basic_monthly' => env('STRIPE_PRICE_ID_BASIC_MONTHLY', null),
- 'stripe_price_id_basic_yearly' => env('STRIPE_PRICE_ID_BASIC_YEARLY', null),
- 'stripe_price_id_pro_monthly' => env('STRIPE_PRICE_ID_PRO_MONTHLY', null),
- 'stripe_price_id_pro_yearly' => env('STRIPE_PRICE_ID_PRO_YEARLY', null),
- 'stripe_price_id_ultimate_monthly' => env('STRIPE_PRICE_ID_ULTIMATE_MONTHLY', null),
- 'stripe_price_id_ultimate_yearly' => env('STRIPE_PRICE_ID_ULTIMATE_YEARLY', null),
'stripe_excluded_plans' => env('STRIPE_EXCLUDED_PLANS', null),
-
- 'stripe_price_id_basic_monthly_old' => env('STRIPE_PRICE_ID_BASIC_MONTHLY_OLD', null),
- 'stripe_price_id_basic_yearly_old' => env('STRIPE_PRICE_ID_BASIC_YEARLY_OLD', null),
- 'stripe_price_id_pro_monthly_old' => env('STRIPE_PRICE_ID_PRO_MONTHLY_OLD', null),
- 'stripe_price_id_pro_yearly_old' => env('STRIPE_PRICE_ID_PRO_YEARLY_OLD', null),
- 'stripe_price_id_ultimate_monthly_old' => env('STRIPE_PRICE_ID_ULTIMATE_MONTHLY_OLD', null),
- 'stripe_price_id_ultimate_yearly_old' => env('STRIPE_PRICE_ID_ULTIMATE_YEARLY_OLD', null),
-
'stripe_price_id_dynamic_monthly' => env('STRIPE_PRICE_ID_DYNAMIC_MONTHLY', null),
'stripe_price_id_dynamic_yearly' => env('STRIPE_PRICE_ID_DYNAMIC_YEARLY', null),
];
diff --git a/config/version.php b/config/version.php
index 79f788c51..3b32ad4af 100644
--- a/config/version.php
+++ b/config/version.php
@@ -1,3 +1,3 @@
longText('custom_nginx_configuration')->nullable()->after('static_image');
+ });
+ }
+
+ /**
+ * Reverse the migrations.
+ */
+ public function down(): void
+ {
+ Schema::table('applications', function (Blueprint $table) {
+ $table->dropColumn('custom_nginx_configuration');
+ });
+ }
+};
diff --git a/docker-compose.prod.yml b/docker-compose.prod.yml
index 80555e377..d86b2336b 100644
--- a/docker-compose.prod.yml
+++ b/docker-compose.prod.yml
@@ -29,6 +29,7 @@ services:
- REDIS_HOST
- REDIS_PASSWORD
- HORIZON_BALANCE
+ - HORIZON_MIN_PROCESSES
- HORIZON_MAX_PROCESSES
- HORIZON_BALANCE_MAX_SHIFT
- HORIZON_BALANCE_COOLDOWN
@@ -50,29 +51,8 @@ services:
- TERMINAL_HOST
- TERMINAL_PORT
- AUTOUPDATE
- - SELF_HOSTED
- SSH_MUX_ENABLED
- SSH_MUX_PERSIST_TIME
- - FEEDBACK_DISCORD_WEBHOOK
- - WAITLIST
- - SUBSCRIPTION_PROVIDER
- - STRIPE_API_KEY
- - STRIPE_WEBHOOK_SECRET
- - STRIPE_PRICE_ID_BASIC_MONTHLY
- - STRIPE_PRICE_ID_BASIC_YEARLY
- - STRIPE_PRICE_ID_PRO_MONTHLY
- - STRIPE_PRICE_ID_PRO_YEARLY
- - STRIPE_PRICE_ID_ULTIMATE_MONTHLY
- - STRIPE_PRICE_ID_ULTIMATE_YEARLY
- - STRIPE_PRICE_ID_DYNAMIC_MONTHLY
- - STRIPE_PRICE_ID_DYNAMIC_YEARLY
- - STRIPE_PRICE_ID_BASIC_MONTHLY_OLD
- - STRIPE_PRICE_ID_BASIC_YEARLY_OLD
- - STRIPE_PRICE_ID_PRO_MONTHLY_OLD
- - STRIPE_PRICE_ID_PRO_YEARLY_OLD
- - STRIPE_PRICE_ID_ULTIMATE_MONTHLY_OLD
- - STRIPE_PRICE_ID_ULTIMATE_YEARLY_OLD
- - STRIPE_EXCLUDED_PLANS
ports:
- "${APP_PORT:-8000}:80"
expose:
diff --git a/other/nightly/docker-compose.prod.yml b/other/nightly/docker-compose.prod.yml
index b15a109c3..d86b2336b 100644
--- a/other/nightly/docker-compose.prod.yml
+++ b/other/nightly/docker-compose.prod.yml
@@ -29,6 +29,7 @@ services:
- REDIS_HOST
- REDIS_PASSWORD
- HORIZON_BALANCE
+ - HORIZON_MIN_PROCESSES
- HORIZON_MAX_PROCESSES
- HORIZON_BALANCE_MAX_SHIFT
- HORIZON_BALANCE_COOLDOWN
@@ -50,29 +51,8 @@ services:
- TERMINAL_HOST
- TERMINAL_PORT
- AUTOUPDATE
- - SELF_HOSTED
- SSH_MUX_ENABLED
- SSH_MUX_PERSIST_TIME
- - FEEDBACK_DISCORD_WEBHOOK
- - WAITLIST
- - SUBSCRIPTION_PROVIDER
- - STRIPE_API_KEY
- - STRIPE_WEBHOOK_SECRET
- - STRIPE_PRICE_ID_BASIC_MONTHLY
- - STRIPE_PRICE_ID_BASIC_YEARLY
- - STRIPE_PRICE_ID_PRO_MONTHLY
- - STRIPE_PRICE_ID_PRO_YEARLY
- - STRIPE_PRICE_ID_ULTIMATE_MONTHLY
- - STRIPE_PRICE_ID_ULTIMATE_YEARLY
- - STRIPE_PRICE_ID_DYNAMIC_MONTHLY
- - STRIPE_PRICE_ID_DYNAMIC_YEARLY
- - STRIPE_PRICE_ID_BASIC_MONTHLY_OLD
- - STRIPE_PRICE_ID_BASIC_YEARLY_OLD
- - STRIPE_PRICE_ID_PRO_MONTHLY_OLD
- - STRIPE_PRICE_ID_PRO_YEARLY_OLD
- - STRIPE_PRICE_ID_ULTIMATE_MONTHLY_OLD
- - STRIPE_PRICE_ID_ULTIMATE_YEARLY_OLD
- - STRIPE_EXCLUDED_PLANS
ports:
- "${APP_PORT:-8000}:80"
expose:
@@ -113,7 +93,7 @@ services:
retries: 10
timeout: 2s
soketi:
- image: 'ghcr.io/coollabsio/coolify-realtime:1.0.3'
+ image: 'ghcr.io/coollabsio/coolify-realtime:1.0.4'
ports:
- "${SOKETI_PORT:-6001}:6001"
- "6002:6002"
diff --git a/other/nightly/upgrade.sh b/other/nightly/upgrade.sh
index 4a9049a5e..670072b12 100644
--- a/other/nightly/upgrade.sh
+++ b/other/nightly/upgrade.sh
@@ -1,11 +1,13 @@
#!/bin/bash
## Do not modify this file. You will lose the ability to autoupdate!
-VERSION="1.2"
+VERSION="13"
CDN="https://cdn.coollabs.io/coolify-nightly"
LATEST_IMAGE=${1:-latest}
LATEST_HELPER_VERSION=${2:-latest}
+
DATE=$(date +%Y-%m-%d-%H-%M-%S)
+LOGFILE="/data/coolify/source/upgrade-${DATE}.log"
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
@@ -32,8 +34,8 @@ docker network create --attachable coolify 2>/dev/null
# docker network create --attachable --driver=overlay coolify-overlay 2>/dev/null
if [ -f /data/coolify/source/docker-compose.custom.yml ]; then
- echo "docker-compose.custom.yml detected."
- docker run -v /data/coolify/source:/data/coolify/source -v /var/run/docker.sock:/var/run/docker.sock --rm ghcr.io/coollabsio/coolify-helper:${LATEST_HELPER_VERSION:-latest} bash -c "LATEST_IMAGE=${1:-} docker compose --env-file /data/coolify/source/.env -f /data/coolify/source/docker-compose.yml -f /data/coolify/source/docker-compose.prod.yml -f /data/coolify/source/docker-compose.custom.yml up -d --remove-orphans --force-recreate --wait --wait-timeout 60" > /data/coolify/source/upgrade-${DATE}.log 2>&1
+ echo "docker-compose.custom.yml detected." >> $LOGFILE
+ docker run -v /data/coolify/source:/data/coolify/source -v /var/run/docker.sock:/var/run/docker.sock --rm ghcr.io/coollabsio/coolify-helper:${LATEST_HELPER_VERSION} bash -c "LATEST_IMAGE=${LATEST_IMAGE} docker compose --env-file /data/coolify/source/.env -f /data/coolify/source/docker-compose.yml -f /data/coolify/source/docker-compose.prod.yml -f /data/coolify/source/docker-compose.custom.yml up -d --remove-orphans --force-recreate --wait --wait-timeout 60" >> $LOGFILE 2>&1
else
- docker run -v /data/coolify/source:/data/coolify/source -v /var/run/docker.sock:/var/run/docker.sock --rm ghcr.io/coollabsio/coolify-helper:${LATEST_HELPER_VERSION:-latest} bash -c "LATEST_IMAGE=${1:-} docker compose --env-file /data/coolify/source/.env -f /data/coolify/source/docker-compose.yml -f /data/coolify/source/docker-compose.prod.yml up -d --remove-orphans --force-recreate --wait --wait-timeout 60" > /data/coolify/source/upgrade-${DATE}.log 2>&1
+ docker run -v /data/coolify/source:/data/coolify/source -v /var/run/docker.sock:/var/run/docker.sock --rm ghcr.io/coollabsio/coolify-helper:${LATEST_HELPER_VERSION} bash -c "LATEST_IMAGE=${LATEST_IMAGE} docker compose --env-file /data/coolify/source/.env -f /data/coolify/source/docker-compose.yml -f /data/coolify/source/docker-compose.prod.yml up -d --remove-orphans --force-recreate --wait --wait-timeout 60" >> $LOGFILE 2>&1
fi
diff --git a/other/nightly/versions.json b/other/nightly/versions.json
index eeb9d77e9..8b10875d0 100644
--- a/other/nightly/versions.json
+++ b/other/nightly/versions.json
@@ -1,10 +1,10 @@
{
"coolify": {
"v4": {
- "version": "4.0.0-beta.363"
+ "version": "4.0.0-beta.367"
},
"nightly": {
- "version": "4.0.0-beta.364"
+ "version": "4.0.0-beta.368"
},
"helper": {
"version": "1.0.3"
@@ -16,4 +16,4 @@
"version": "0.0.15"
}
}
-}
+}
\ No newline at end of file
diff --git a/resources/views/livewire/project/application/general.blade.php b/resources/views/livewire/project/application/general.blade.php
index 99f6b3d08..19cb4bdfc 100644
--- a/resources/views/livewire/project/application/general.blade.php
+++ b/resources/views/livewire/project/application/general.blade.php
@@ -61,8 +61,16 @@
@endif
+ @if ($application->settings->is_static || $application->build_pack === 'static')
+