mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-02 22:46:16 +00:00
* wip * wip * cleanup * notification channels * phpstan * services * remove server types * refactoring * refactoring
54 lines
1.4 KiB
PHP
54 lines
1.4 KiB
PHP
<?php
|
|
|
|
namespace Database\Seeders;
|
|
|
|
use App\Models\NotificationChannel;
|
|
use App\NotificationChannels\Discord;
|
|
use App\NotificationChannels\Email;
|
|
use App\NotificationChannels\Slack;
|
|
use App\NotificationChannels\Telegram;
|
|
use Illuminate\Database\Seeder;
|
|
|
|
class NotificationChannelsSeeder extends Seeder
|
|
{
|
|
public function run(): void
|
|
{
|
|
NotificationChannel::factory()->create([
|
|
'label' => 'Slack',
|
|
'provider' => Slack::id(),
|
|
'data' => [
|
|
'webhook' => 'slack_webhook',
|
|
],
|
|
'connected' => 1,
|
|
]);
|
|
|
|
NotificationChannel::factory()->create([
|
|
'label' => 'Discord',
|
|
'provider' => Discord::id(),
|
|
'data' => [
|
|
'webhook' => 'discord_webhook',
|
|
],
|
|
'connected' => 1,
|
|
]);
|
|
|
|
NotificationChannel::factory()->create([
|
|
'label' => 'Telegram',
|
|
'provider' => Telegram::id(),
|
|
'data' => [
|
|
'token' => 'telegram_token',
|
|
'chat_id' => 'telegram_chat_id',
|
|
],
|
|
'connected' => 1,
|
|
]);
|
|
|
|
NotificationChannel::factory()->create([
|
|
'label' => 'Email',
|
|
'provider' => Email::id(),
|
|
'data' => [
|
|
'email' => 'email@vitodeploy.com',
|
|
],
|
|
'connected' => 1,
|
|
]);
|
|
}
|
|
}
|