An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.
PHP coolifydatabasesdeploymentdockerdocker-composeinertiajslaravelmariadbmysqlnextjsnodejsphppostgresredisself-hostedself-hostingserverstatic-sitesveltesvelte5
feat: Update server settings metrics history days to 7
Andras Bacsai4fb37054df55
diff --git a/database/migrations/2024_06_25_184323_update_db.php b/database/migrations/2024_06_25_184323_update_db.phpindex ef6ee74f7b..c57c4d4030 100644--- a/database/migrations/2024_06_25_184323_update_db.php+++ b/database/migrations/2024_06_25_184323_update_db.php@@ -1,6 +1,7 @@<?phpuse App\Models\EnvironmentVariable;+use App\Models\Server;use Illuminate\Database\Migrations\Migration;use Illuminate\Database\Schema\Blueprint;use Illuminate\Support\Facades\Schema;@@ -30,6 +31,14 @@ return new class extends MigrationSchema::table('environment_variables', function (Blueprint $table) {$table->string('uuid')->nullable(false)->change();});+ Schema::table('server_settings', function (Blueprint $table) {+ $table->integer('metrics_history_days')->default(7)->change();+ });+ Server::all()->each(function (Server $server) {+ $server->settings->update([+ 'metrics_history_days' => 7,+ ]);+ });}/**@@ -45,6 +54,13 @@ return new class extends MigrationSchema::table('environment_variables', function (Blueprint $table) {$table->dropColumn('uuid');});-+ Schema::table('server_settings', function (Blueprint $table) {+ $table->integer('metrics_history_days')->default(30)->change();+ });+ Server::all()->each(function (Server $server) {+ $server->settings->update([+ 'metrics_history_days' => 30,+ ]);+ });}};