diff --git a/.env.example b/.env.example index 5805e6395..32b347fbf 100644 --- a/.env.example +++ b/.env.example @@ -9,7 +9,7 @@ APP_LOCALE=en APP_FALLBACK_LOCALE=en APP_FAKER_LOCALE=en_US -APP_MAINTENANCE_DRIVER=file +APP_MAINTENANCE_DRIVER=cache APP_MAINTENANCE_STORE=database LOG_CHANNEL=stack @@ -17,18 +17,18 @@ LOG_STACK=single LOG_DEPRECATIONS_CHANNEL=null LOG_LEVEL=debug -DB_CONNECTION=mysql -DB_HOST=127.0.0.1 -DB_PORT=3306 -DB_DATABASE=laravel -DB_USERNAME=root -DB_PASSWORD= +DB_CONNECTION=sqlite +# DB_HOST=127.0.0.1 +# DB_PORT=3306 +# DB_DATABASE=laravel +# DB_USERNAME=root +# DB_PASSWORD= BROADCAST_CONNECTION=log CACHE_STORE=database FILESYSTEM_DISK=local QUEUE_CONNECTION=database -SESSION_DRIVER=cookie +SESSION_DRIVER=database SESSION_LIFETIME=120 MEMCACHED_HOST=127.0.0.1 diff --git a/composer.json b/composer.json index d621ea202..b70813c0a 100644 --- a/composer.json +++ b/composer.json @@ -43,7 +43,9 @@ "@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" ], "post-create-project-cmd": [ - "@php artisan key:generate --ansi" + "@php artisan key:generate --ansi", + "@php -r \"file_exists('database/database.sqlite') || touch('database/database.sqlite');\"", + "@php artisan migrate --ansi" ] }, "extra": { diff --git a/database/migrations/0001_01_01_000002_create_jobs_table.php b/database/migrations/0001_01_01_000002_create_jobs_table.php index cd80d4213..425e7058f 100644 --- a/database/migrations/0001_01_01_000002_create_jobs_table.php +++ b/database/migrations/0001_01_01_000002_create_jobs_table.php @@ -21,6 +21,19 @@ return new class extends Migration $table->unsignedInteger('created_at'); }); + Schema::create('job_batches', function (Blueprint $table) { + $table->string('id')->primary(); + $table->string('name'); + $table->integer('total_jobs'); + $table->integer('pending_jobs'); + $table->integer('failed_jobs'); + $table->longText('failed_job_ids'); + $table->mediumText('options')->nullable(); + $table->integer('cancelled_at')->nullable(); + $table->integer('created_at'); + $table->integer('finished_at')->nullable(); + }); + Schema::create('failed_jobs', function (Blueprint $table) { $table->id(); $table->string('uuid')->unique(); @@ -38,6 +51,7 @@ return new class extends Migration public function down(): void { Schema::dropIfExists('jobs'); + Schema::dropIfExists('job_batches'); Schema::dropIfExists('failed_jobs'); } };