coolify/database/seeders/ApplicationSeeder.php

67 lines
2.2 KiB
PHP
Raw Normal View History

<?php
namespace Database\Seeders;
use App\Models\Application;
2023-03-28 12:09:34 +02:00
use App\Models\GithubApp;
2023-03-27 14:31:42 +02:00
use App\Models\StandaloneDocker;
use Illuminate\Database\Seeder;
class ApplicationSeeder extends Seeder
{
/**
* Run the database seeds.
*/
public function run(): void
{
2023-03-27 18:14:33 +02:00
Application::create([
'name' => 'NodeJS Fastify Example',
2023-08-25 12:40:53 +02:00
'fqdn' => 'http://nodejs.127.0.0.1.sslip.io',
2023-05-11 15:20:02 +02:00
'repository_project_id' => 603035348,
2023-03-28 15:47:37 +02:00
'git_repository' => 'coollabsio/coolify-examples',
'git_branch' => 'main',
'base_directory' => '/nodejs',
2023-03-28 15:47:37 +02:00
'build_pack' => 'nixpacks',
'ports_exposes' => '3000',
2023-08-07 18:46:40 +02:00
'environment_id' => 1,
2023-08-11 16:13:53 +02:00
'destination_id' => 0,
2023-03-27 14:31:42 +02:00
'destination_type' => StandaloneDocker::class,
2023-11-03 15:11:06 +01:00
'source_id' => 1,
2024-06-10 22:43:34 +02:00
'source_type' => GithubApp::class,
2023-08-11 22:41:47 +02:00
]);
Application::create([
'name' => 'Dockerfile Example',
2023-08-25 12:40:53 +02:00
'fqdn' => 'http://dockerfile.127.0.0.1.sslip.io',
2023-08-11 22:41:47 +02:00
'repository_project_id' => 603035348,
'git_repository' => 'coollabsio/coolify-examples',
'git_branch' => 'main',
'base_directory' => '/dockerfile',
2023-08-11 22:41:47 +02:00
'build_pack' => 'dockerfile',
2023-10-20 12:34:53 +02:00
'ports_exposes' => '80',
2023-08-11 22:41:47 +02:00
'environment_id' => 1,
'destination_id' => 0,
'destination_type' => StandaloneDocker::class,
'source_id' => 0,
2024-06-10 22:43:34 +02:00
'source_type' => GithubApp::class,
]);
2023-08-25 12:40:53 +02:00
Application::create([
'name' => 'Pure Dockerfile Example',
2023-08-25 12:40:53 +02:00
'fqdn' => 'http://pure-dockerfile.127.0.0.1.sslip.io',
'git_repository' => 'coollabsio/coolify',
'git_branch' => 'main',
'git_commit_sha' => 'HEAD',
'build_pack' => 'dockerfile',
'ports_exposes' => '80',
'environment_id' => 1,
'destination_id' => 0,
'destination_type' => StandaloneDocker::class,
'source_id' => 0,
'source_type' => GithubApp::class,
'dockerfile' => 'FROM nginx
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]
2024-06-10 22:43:34 +02:00
',
2023-08-25 12:40:53 +02:00
]);
}
}