feat: configuration checker for all resources

This commit is contained in:
Andras Bacsai
2024-04-12 12:44:49 +02:00
parent 7b0018b661
commit 7a32b8d1d2
41 changed files with 493 additions and 89 deletions

View File

@@ -18,7 +18,6 @@ return new class extends Migration
$table->string('description')->nullable();
$table->text('dragonfly_password');
$table->longText('dragonfly_conf')->nullable();
$table->boolean('is_log_drain_enabled')->default(false);
$table->boolean('is_include_timestamps')->default(false);

View File

@@ -0,0 +1,76 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::table('standalone_postgresqls', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_redis', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_mysqls', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_mariadbs', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_mongodbs', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_keydbs', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_dragonflies', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('standalone_clickhouses', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
Schema::table('services', function (Blueprint $table) {
$table->string('config_hash')->nullable();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('standalone_postgresqls', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_redis', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_mysqls', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_mariadbs', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_mongodbs', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_keydbs', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_dragonflies', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('standalone_clickhouses', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
Schema::table('services', function (Blueprint $table) {
$table->dropColumn('config_hash');
});
}
};