2021-06-05 09:26:32 +00:00
< ? php
2021-06-22 15:13:24 +00:00
namespace Database\Seeders\Seeds ;
2021-06-05 09:26:32 +00:00
use App\Models\Configuration ;
use Illuminate\Database\Seeder ;
class ConfigurationSeeder extends Seeder
{
/**
* Run the database seeds .
*
* @ return void
*/
public function run ()
{
//initials
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'INITIAL_CREDITS' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '250' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'The initial amount of credits the user starts with.'
2021-06-05 09:26:32 +00:00
]);
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'INITIAL_SERVER_LIMIT' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '1' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'The initial server limit the user starts with.'
2021-06-05 09:26:32 +00:00
]);
//verify email event
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'CREDITS_REWARD_AFTER_VERIFY_EMAIL' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '250' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'Increase in credits after the user has verified their email account.'
2021-06-05 09:26:32 +00:00
]);
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'SERVER_LIMIT_REWARD_AFTER_VERIFY_EMAIL' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '2' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'Increase in server limit after the user has verified their email account.'
2021-06-05 09:26:32 +00:00
]);
//verify discord event
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
2021-06-27 13:53:49 +00:00
'key' => 'CREDITS_REWARD_AFTER_VERIFY_DISCORD' ,
], [
'value' => '375' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'Increase in credits after the user has verified their discord account.'
2021-06-05 09:26:32 +00:00
]);
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'SERVER_LIMIT_REWARD_AFTER_VERIFY_DISCORD' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '2' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'Increase in server limit after the user has verified their discord account.'
2021-06-05 09:26:32 +00:00
]);
//other
2021-06-07 15:30:19 +00:00
Configuration :: firstOrCreate ([
'key' => 'MINIMUM_REQUIRED_CREDITS_TO_MAKE_SERVER' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '50' ,
'type' => 'integer' ,
2021-06-22 15:26:42 +00:00
'description' => 'The minimum amount of credits the user would need to make a server.'
]);
//purchasing
Configuration :: firstOrCreate ([
'key' => 'SERVER_LIMIT_AFTER_IRL_PURCHASE' ,
], [
2021-06-27 13:53:49 +00:00
'value' => '10' ,
'type' => 'integer' ,
2021-06-22 19:25:04 +00:00
'description' => 'updates the users server limit to this amount (unless the user already has a higher server limit) after making a purchase with real money, set to 0 to ignore this.' ,
2021-06-05 09:26:32 +00:00
]);
2021-06-26 20:04:23 +00:00
2021-06-27 13:53:49 +00:00
//force email and discord verification
2021-06-26 20:04:23 +00:00
Configuration :: firstOrCreate ([
2021-06-27 13:53:49 +00:00
'key' => 'FORCE_EMAIL_VERIFICATION' ,
], [
'value' => 'false' ,
'type' => 'boolean' ,
2021-06-26 20:04:23 +00:00
'description' => 'Force an user to verify the email adress before creating a server / buying credits.'
]);
Configuration :: firstOrCreate ([
2021-06-27 13:53:49 +00:00
'key' => 'FORCE_DISCORD_VERIFICATION' ,
], [
'value' => 'false' ,
'type' => 'boolean' ,
2021-06-26 20:04:23 +00:00
'description' => 'Force an user to link an Discord Account before creating a server / buying credits.'
]);
2021-06-27 13:53:49 +00:00
//disable ip check on register
Configuration :: firstOrCreate ([
'key' => 'REGISTER_IP_CHECK' ,
], [
'value' => 'true' ,
'type' => 'boolean' ,
'description' => 'Prevent users from making multiple accounts using the same IP address'
]);
2021-07-05 18:47:29 +00:00
//per_page on allocations request
Configuration :: firstOrCreate ([
'key' => 'ALLOCATION_LIMIT' ,
], [
'value' => '200' ,
'type' => 'integer' ,
'description' => 'The maximum amount of allocations to pull per node for automatic deployment, if more allocations are being used than this limit is set to, no new servers can be created!'
]);
2021-06-05 09:26:32 +00:00
}
}