This breaks literally the entire panel.
This commit is contained in:
parent
344c1a9885
commit
df87ea0867
88 changed files with 1205 additions and 992 deletions
|
@ -88,7 +88,7 @@ $factory->define(Pterodactyl\Models\Node::class, function (Faker\Generator $fake
|
|||
];
|
||||
});
|
||||
|
||||
$factory->define(Pterodactyl\Models\Service::class, function (Faker\Generator $faker) {
|
||||
$factory->define(Pterodactyl\Models\Nest::class, function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->randomNumber(),
|
||||
'uuid' => $faker->unique()->uuid,
|
||||
|
@ -98,7 +98,7 @@ $factory->define(Pterodactyl\Models\Service::class, function (Faker\Generator $f
|
|||
];
|
||||
});
|
||||
|
||||
$factory->define(Pterodactyl\Models\ServiceOption::class, function (Faker\Generator $faker) {
|
||||
$factory->define(Pterodactyl\Models\Egg::class, function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->randomNumber(),
|
||||
'uuid' => $faker->unique()->uuid,
|
||||
|
@ -109,7 +109,7 @@ $factory->define(Pterodactyl\Models\ServiceOption::class, function (Faker\Genera
|
|||
];
|
||||
});
|
||||
|
||||
$factory->define(Pterodactyl\Models\ServiceVariable::class, function (Faker\Generator $faker) {
|
||||
$factory->define(Pterodactyl\Models\EggVariable::class, function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->randomNumber(),
|
||||
'name' => $faker->firstName,
|
||||
|
@ -122,11 +122,11 @@ $factory->define(Pterodactyl\Models\ServiceVariable::class, function (Faker\Gene
|
|||
];
|
||||
});
|
||||
|
||||
$factory->state(Pterodactyl\Models\ServiceVariable::class, 'viewable', function () {
|
||||
$factory->state(Pterodactyl\Models\EggVariable::class, 'viewable', function () {
|
||||
return ['user_viewable' => 1];
|
||||
});
|
||||
|
||||
$factory->state(Pterodactyl\Models\ServiceVariable::class, 'editable', function () {
|
||||
$factory->state(Pterodactyl\Models\EggVariable::class, 'editable', function () {
|
||||
return ['user_editable' => 1];
|
||||
});
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<?php
|
||||
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
@ -13,31 +12,6 @@ class DeleteServiceExecutableOption extends Migration
|
|||
public function up()
|
||||
{
|
||||
DB::transaction(function () {
|
||||
// Attempt to fix any startup commands for servers
|
||||
// that we possibly can. Also set new containers.
|
||||
foreach (ServiceOption::with('servers')->get() as $option) {
|
||||
$option->servers->each(function ($s) use ($option) {
|
||||
$prepend = $option->display_executable;
|
||||
$prepend = ($prepend === './ShooterGameServer') ? './ShooterGame/Binaries/Linux/ShooterGameServer' : $prepend;
|
||||
$prepend = ($prepend === 'TerrariaServer.exe') ? 'mono TerrariaServer.exe' : $prepend;
|
||||
|
||||
$s->startup = $prepend . ' ' . $s->startup;
|
||||
|
||||
$container = $s->container;
|
||||
if (starts_with($container, 'quay.io/pterodactyl/minecraft')) {
|
||||
$s->container = 'quay.io/pterodactyl/core:java';
|
||||
} elseif (starts_with($container, 'quay.io/pterodactyl/srcds')) {
|
||||
$s->container = 'quay.io/pterodactyl/core:source';
|
||||
} elseif (starts_with($container, 'quay.io/pterodactyl/voice')) {
|
||||
$s->container = 'quay.io/pterodactyl/core:glibc';
|
||||
} elseif (starts_with($container, 'quay.io/pterodactyl/terraria')) {
|
||||
$s->container = 'quay.io/pterodactyl/core:mono';
|
||||
}
|
||||
|
||||
$s->save();
|
||||
});
|
||||
}
|
||||
|
||||
Schema::table('services', function (Blueprint $table) {
|
||||
$table->renameColumn('file', 'folder');
|
||||
$table->dropColumn('executable');
|
||||
|
|
|
@ -6,8 +6,6 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class MigrateToNewServiceSystem extends Migration
|
||||
|
@ -18,12 +16,12 @@ class MigrateToNewServiceSystem extends Migration
|
|||
public function up()
|
||||
{
|
||||
DB::transaction(function () {
|
||||
$service = Service::where('author', config('pterodactyl.service.core'))->where('folder', 'srcds')->first();
|
||||
$service = DB::table('services')->where('author', config('pterodactyl.service.core'))->where('folder', 'srcds')->first();
|
||||
if (! $service) {
|
||||
return;
|
||||
}
|
||||
|
||||
$options = ServiceOption::where('service_id', $service->id)->get();
|
||||
$options = DB::table('service_options')->where('service_id', $service->id)->get();
|
||||
$options->each(function ($item) use ($options) {
|
||||
if ($item->tag === 'srcds' && $item->name === 'Insurgency') {
|
||||
$item->tag = 'insurgency';
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
|
@ -17,7 +16,7 @@ class ChangeServiceVariablesValidationRules extends Migration
|
|||
});
|
||||
|
||||
DB::transaction(function () {
|
||||
foreach (ServiceVariable::all() as $variable) {
|
||||
foreach (DB::table('service_variables')->get() as $variable) {
|
||||
$variable->rules = ($variable->required) ? 'required|regex:' . $variable->rules : 'regex:' . $variable->rules;
|
||||
$variable->save();
|
||||
}
|
||||
|
@ -39,7 +38,7 @@ class ChangeServiceVariablesValidationRules extends Migration
|
|||
});
|
||||
|
||||
DB::transaction(function () {
|
||||
foreach (ServiceVariable::all() as $variable) {
|
||||
foreach (DB::table('service_variables')->get() as $variable) {
|
||||
$variable->regex = str_replace(['required|regex:', 'regex:'], '', $variable->regex);
|
||||
$variable->save();
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<?php
|
||||
|
||||
use Pterodactyl\Models\Service;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
@ -93,11 +92,11 @@ EOF;
|
|||
});
|
||||
|
||||
DB::transaction(function () {
|
||||
Service::where('author', 'ptrdctyl-v040-11e6-8b77-86f30ca893d3')->where('folder', '!=', 'minecraft')->update([
|
||||
DB::table('services')->where('author', 'ptrdctyl-v040-11e6-8b77-86f30ca893d3')->where('folder', '!=', 'minecraft')->update([
|
||||
'index_file' => $this->default,
|
||||
]);
|
||||
|
||||
Service::where('author', 'ptrdctyl-v040-11e6-8b77-86f30ca893d3')->where('folder', 'minecraft')->update([
|
||||
DB::table('services')->where('author', 'ptrdctyl-v040-11e6-8b77-86f30ca893d3')->where('folder', 'minecraft')->update([
|
||||
'index_file' => $this->default_mc,
|
||||
]);
|
||||
});
|
||||
|
|
|
@ -15,6 +15,7 @@ class ChangeToABetterUniqueServiceConfiguration extends Migration
|
|||
{
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->char('uuid', 36)->after('id');
|
||||
$table->string('author')->after('service_id');
|
||||
$table->dropColumn('tag');
|
||||
});
|
||||
|
||||
|
@ -25,6 +26,7 @@ class ChangeToABetterUniqueServiceConfiguration extends Migration
|
|||
'services.author AS service_author',
|
||||
])->join('services', 'services.id', '=', 'service_options.service_id')->get()->each(function ($option) {
|
||||
DB::table('service_options')->where('id', $option->id)->update([
|
||||
'author' => $option->service_author,
|
||||
'uuid' => Uuid::uuid4()->toString(),
|
||||
]);
|
||||
});
|
||||
|
@ -42,6 +44,7 @@ class ChangeToABetterUniqueServiceConfiguration extends Migration
|
|||
{
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->dropColumn('uuid');
|
||||
$table->dropColumn('author');
|
||||
$table->string('tag');
|
||||
});
|
||||
|
||||
|
|
|
@ -0,0 +1,59 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ServicesToNestsConversion extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::rename('services', 'nests');
|
||||
|
||||
Schema::table('servers', function (Blueprint $table) {
|
||||
$table->dropForeign(['service_id']);
|
||||
$table->renameColumn('service_id', 'nest_id');
|
||||
|
||||
$table->foreign('nest_id')->references('id')->on('nests');
|
||||
});
|
||||
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->dropForeign(['service_id']);
|
||||
$table->renameColumn('service_id', 'nest_id');
|
||||
|
||||
$table->foreign('nest_id')->references('id')->on('nests')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::rename('nests', 'services');
|
||||
|
||||
Schema::table('servers', function (Blueprint $table) {
|
||||
$table->dropForeign(['nest_id']);
|
||||
$table->renameColumn('nest_id', 'service_id');
|
||||
|
||||
$table->foreign('service_id')->references('id')->on('services');
|
||||
});
|
||||
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->dropForeign(['nest_id']);
|
||||
$table->renameColumn('nest_id', 'service_id');
|
||||
|
||||
$table->foreign('service_id')->references('id')->on('services')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,93 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ServiceOptionsToEggsConversion extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->dropForeign(['config_from']);
|
||||
$table->dropForeign(['copy_script_from']);
|
||||
});
|
||||
|
||||
Schema::rename('service_options', 'eggs');
|
||||
|
||||
Schema::table('packs', function (Blueprint $table) {
|
||||
$table->dropForeign(['option_id']);
|
||||
$table->renameColumn('option_id', 'egg_id');
|
||||
|
||||
$table->foreign('egg_id')->references('id')->on('eggs')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::table('servers', function (Blueprint $table) {
|
||||
$table->dropForeign(['option_id']);
|
||||
$table->renameColumn('option_id', 'egg_id');
|
||||
|
||||
$table->foreign('egg_id')->references('id')->on('eggs');
|
||||
});
|
||||
|
||||
Schema::table('eggs', function (Blueprint $table) {
|
||||
$table->foreign('config_from')->references('id')->on('eggs')->onDelete('SET NULL');
|
||||
$table->foreign('copy_script_from')->references('id')->on('eggs')->onDelete('SET NULL');
|
||||
});
|
||||
|
||||
Schema::table('service_variables', function (Blueprint $table) {
|
||||
$table->dropForeign(['option_id']);
|
||||
$table->renameColumn('option_id', 'egg_id');
|
||||
|
||||
$table->foreign('egg_id')->references('id')->on('eggs')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::table('eggs', function (Blueprint $table) {
|
||||
$table->dropForeign(['config_from']);
|
||||
$table->dropForeign(['copy_script_from']);
|
||||
});
|
||||
|
||||
Schema::rename('eggs', 'service_options');
|
||||
|
||||
Schema::table('packs', function (Blueprint $table) {
|
||||
$table->dropForeign(['egg_id']);
|
||||
$table->renameColumn('egg_id', 'option_id');
|
||||
|
||||
$table->foreign('option_id')->references('id')->on('service_options')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::table('servers', function (Blueprint $table) {
|
||||
$table->dropForeign(['egg_id']);
|
||||
$table->renameColumn('egg_id', 'option_id');
|
||||
|
||||
$table->foreign('option_id')->references('id')->on('service_options');
|
||||
});
|
||||
|
||||
Schema::table('service_options', function (Blueprint $table) {
|
||||
$table->foreign('config_from')->references('id')->on('service_options')->onDelete('SET NULL');
|
||||
$table->foreign('copy_script_from')->references('id')->on('service_options')->onDelete('SET NULL');
|
||||
});
|
||||
|
||||
Schema::table('service_variables', function (Blueprint $table) {
|
||||
$table->dropForeign(['egg_id']);
|
||||
$table->renameColumn('egg_id', 'option_id');
|
||||
|
||||
$table->foreign('option_id')->references('id')->on('options')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,43 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class ServiceVariablesToEggVariablesConversion extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::rename('service_variables', 'egg_variables');
|
||||
|
||||
Schema::table('server_variables', function (Blueprint $table) {
|
||||
$table->dropForeign(['variable_id']);
|
||||
|
||||
$table->foreign('variable_id')->references('id')->on('egg_variables')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::disableForeignKeyConstraints();
|
||||
|
||||
Schema::rename('egg_variables', 'service_variables');
|
||||
|
||||
Schema::table('server_variables', function (Blueprint $table) {
|
||||
$table->dropForeign(['variable_id']);
|
||||
|
||||
$table->foreign('variable_id')->references('id')->on('service_variables')->onDelete('CASCADE');
|
||||
});
|
||||
|
||||
Schema::enableForeignKeyConstraints();
|
||||
}
|
||||
}
|
|
@ -6,17 +6,17 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Egg;
|
||||
use Pterodactyl\Models\Nest;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
|
||||
class MinecraftServiceTableSeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
* The core service ID.
|
||||
*
|
||||
* @var \Pterodactyl\Models\Service
|
||||
* @var \Pterodactyl\Models\Nest
|
||||
*/
|
||||
protected $service;
|
||||
|
||||
|
@ -80,7 +80,7 @@ EOF;
|
|||
|
||||
private function addCoreService()
|
||||
{
|
||||
$this->service = Service::updateOrCreate([
|
||||
$this->service = Nest::updateOrCreate([
|
||||
'author' => config('pterodactyl.service.core'),
|
||||
'folder' => 'minecraft',
|
||||
], [
|
||||
|
@ -114,7 +114,7 @@ fi
|
|||
curl -o ${SERVER_JARFILE} https://s3.amazonaws.com/Minecraft.Download/versions/${DL_VERSION}/minecraft_server.${DL_VERSION}.jar
|
||||
EOF;
|
||||
|
||||
$this->option['vanilla'] = ServiceOption::updateOrCreate([
|
||||
$this->option['vanilla'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'vanilla',
|
||||
], [
|
||||
|
@ -148,7 +148,7 @@ if [ ! -z "${DL_PATH}" ]; then
|
|||
fi
|
||||
EOF;
|
||||
|
||||
$this->option['spigot'] = ServiceOption::updateOrCreate([
|
||||
$this->option['spigot'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'spigot',
|
||||
], [
|
||||
|
@ -178,7 +178,7 @@ cd /mnt/server
|
|||
curl -sSL "https://repo.spongepowered.org/maven/org/spongepowered/spongevanilla/${SPONGE_VERSION}/spongevanilla-${SPONGE_VERSION}.jar" -o ${SERVER_JARFILE}
|
||||
EOF;
|
||||
|
||||
$this->option['sponge'] = ServiceOption::updateOrCreate([
|
||||
$this->option['sponge'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'sponge',
|
||||
], [
|
||||
|
@ -211,7 +211,7 @@ fi
|
|||
curl -o ${SERVER_JARFILE} https://ci.md-5.net/job/BungeeCord/${BUNGEE_VERSION}/artifact/bootstrap/target/BungeeCord.jar
|
||||
EOF;
|
||||
|
||||
$this->option['bungeecord'] = ServiceOption::updateOrCreate([
|
||||
$this->option['bungeecord'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'bungeecord',
|
||||
], [
|
||||
|
@ -247,7 +247,7 @@ java -jar installer.jar --installServer
|
|||
rm -rf installer.jar
|
||||
EOF;
|
||||
|
||||
$this->option['forge'] = ServiceOption::updateOrCreate([
|
||||
$this->option['forge'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'forge',
|
||||
], [
|
||||
|
@ -276,7 +276,7 @@ EOF;
|
|||
|
||||
private function addVanillaVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['vanilla']->id,
|
||||
'env_variable' => 'SERVER_JARFILE',
|
||||
], [
|
||||
|
@ -288,7 +288,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^([\w\d._-]+)(\.jar)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['vanilla']->id,
|
||||
'env_variable' => 'VANILLA_VERSION',
|
||||
], [
|
||||
|
@ -303,7 +303,7 @@ EOF;
|
|||
|
||||
private function addSpigotVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['spigot']->id,
|
||||
'env_variable' => 'SERVER_JARFILE',
|
||||
], [
|
||||
|
@ -315,7 +315,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^([\w\d._-]+)(\.jar)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['spigot']->id,
|
||||
'env_variable' => 'DL_VERSION',
|
||||
], [
|
||||
|
@ -327,7 +327,7 @@ EOF;
|
|||
'rules' => 'required|string|between:3,7',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['spigot']->id,
|
||||
'env_variable' => 'DL_PATH',
|
||||
], [
|
||||
|
@ -342,7 +342,7 @@ EOF;
|
|||
|
||||
private function addSpongeVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['sponge']->id,
|
||||
'env_variable' => 'SPONGE_VERSION',
|
||||
], [
|
||||
|
@ -354,7 +354,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^([a-zA-Z0-9.\-_]+)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['sponge']->id,
|
||||
'env_variable' => 'SERVER_JARFILE',
|
||||
], [
|
||||
|
@ -369,7 +369,7 @@ EOF;
|
|||
|
||||
private function addBungeecordVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['bungeecord']->id,
|
||||
'env_variable' => 'BUNGEE_VERSION',
|
||||
], [
|
||||
|
@ -381,7 +381,7 @@ EOF;
|
|||
'rules' => 'required|alpha_num|between:1,6',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['bungeecord']->id,
|
||||
'env_variable' => 'SERVER_JARFILE',
|
||||
], [
|
||||
|
@ -396,7 +396,7 @@ EOF;
|
|||
|
||||
private function addForgeVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['forge']->id,
|
||||
'env_variable' => 'SERVER_JARFILE',
|
||||
], [
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Egg;
|
||||
use Pterodactyl\Models\Nest;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
use Pterodactyl\Traits\Services\CreatesServiceIndex;
|
||||
|
||||
class RustServiceTableSeeder extends Seeder
|
||||
|
@ -42,7 +42,7 @@ class RustServiceTableSeeder extends Seeder
|
|||
|
||||
private function addCoreService()
|
||||
{
|
||||
$this->service = Service::updateOrCreate([
|
||||
$this->service = Nest::updateOrCreate([
|
||||
'author' => config('pterodactyl.service.core'),
|
||||
'folder' => 'rust',
|
||||
], [
|
||||
|
@ -75,7 +75,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['rustvanilla'] = ServiceOption::updateOrCreate([
|
||||
$this->option['rustvanilla'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'rustvanilla',
|
||||
], [
|
||||
|
@ -119,7 +119,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v /mnt/server/steam/linux32/steamclient.so /mnt/server/.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['rustoxide'] = ServiceOption::updateOrCreate([
|
||||
$this->option['rustoxide'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'rustoxide',
|
||||
], [
|
||||
|
@ -146,7 +146,7 @@ EOF;
|
|||
|
||||
private function addVanillaVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'HOSTNAME',
|
||||
], [
|
||||
|
@ -158,7 +158,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'LEVEL',
|
||||
], [
|
||||
|
@ -170,7 +170,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'DESCRIPTION',
|
||||
], [
|
||||
|
@ -182,7 +182,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'URL',
|
||||
], [
|
||||
|
@ -194,7 +194,7 @@ EOF;
|
|||
'rules' => 'url',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'WORLD_SIZE',
|
||||
], [
|
||||
|
@ -206,7 +206,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'SEED',
|
||||
], [
|
||||
|
@ -218,7 +218,7 @@ EOF;
|
|||
'rules' => 'present',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'MAX_PLAYERS',
|
||||
], [
|
||||
|
@ -230,7 +230,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'SERVER_IMG',
|
||||
], [
|
||||
|
@ -242,7 +242,7 @@ EOF;
|
|||
'rules' => 'url',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'RCON_PORT',
|
||||
], [
|
||||
|
@ -254,7 +254,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'RCON_PASS',
|
||||
], [
|
||||
|
@ -266,7 +266,7 @@ EOF;
|
|||
'rules' => 'required',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustvanilla']->id,
|
||||
'env_variable' => 'ADDITIONAL_ARGS',
|
||||
], [
|
||||
|
@ -281,7 +281,7 @@ EOF;
|
|||
|
||||
private function addOxideVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'HOSTNAME',
|
||||
], [
|
||||
|
@ -293,7 +293,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'LEVEL',
|
||||
], [
|
||||
|
@ -305,7 +305,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'DESCRIPTION',
|
||||
], [
|
||||
|
@ -317,7 +317,7 @@ EOF;
|
|||
'rules' => 'required|string',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'URL',
|
||||
], [
|
||||
|
@ -329,7 +329,7 @@ EOF;
|
|||
'rules' => 'url',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'WORLD_SIZE',
|
||||
], [
|
||||
|
@ -341,7 +341,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'SEED',
|
||||
], [
|
||||
|
@ -353,7 +353,7 @@ EOF;
|
|||
'rules' => 'present',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'MAX_PLAYERS',
|
||||
], [
|
||||
|
@ -365,7 +365,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'SERVER_IMG',
|
||||
], [
|
||||
|
@ -377,7 +377,7 @@ EOF;
|
|||
'rules' => 'url',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'RCON_PORT',
|
||||
], [
|
||||
|
@ -389,7 +389,7 @@ EOF;
|
|||
'rules' => 'required|integer',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'RCON_PASS',
|
||||
], [
|
||||
|
@ -401,7 +401,7 @@ EOF;
|
|||
'rules' => 'required',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['rustoxide']->id,
|
||||
'env_variable' => 'ADDITIONAL_ARGS',
|
||||
], [
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Egg;
|
||||
use Pterodactyl\Models\Nest;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
use Pterodactyl\Traits\Services\CreatesServiceIndex;
|
||||
|
||||
class SourceServiceTableSeeder extends Seeder
|
||||
|
@ -42,7 +42,7 @@ class SourceServiceTableSeeder extends Seeder
|
|||
|
||||
private function addCoreService()
|
||||
{
|
||||
$this->service = Service::updateOrCreate([
|
||||
$this->service = Nest::updateOrCreate([
|
||||
'author' => config('pterodactyl.service.core'),
|
||||
'folder' => 'srcds',
|
||||
], [
|
||||
|
@ -81,7 +81,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['source'] = ServiceOption::updateOrCreate([
|
||||
$this->option['source'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'source',
|
||||
], [
|
||||
|
@ -99,7 +99,7 @@ EOF;
|
|||
'script_container' => 'ubuntu:16.04',
|
||||
]);
|
||||
|
||||
$this->option['insurgency'] = ServiceOption::updateOrCreate([
|
||||
$this->option['insurgency'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'insurgency',
|
||||
], [
|
||||
|
@ -115,7 +115,7 @@ EOF;
|
|||
'copy_script_from' => $this->option['source']->id,
|
||||
]);
|
||||
|
||||
$this->option['tf2'] = ServiceOption::updateOrCreate([
|
||||
$this->option['tf2'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'tf2',
|
||||
], [
|
||||
|
@ -161,7 +161,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['ark'] = ServiceOption::updateOrCreate([
|
||||
$this->option['ark'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'ark',
|
||||
], [
|
||||
|
@ -205,7 +205,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['csgo'] = ServiceOption::updateOrCreate([
|
||||
$this->option['csgo'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'csgo',
|
||||
], [
|
||||
|
@ -249,7 +249,7 @@ mkdir -p /mnt/server/.steam/sdk32
|
|||
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
|
||||
EOF;
|
||||
|
||||
$this->option['gmod'] = ServiceOption::updateOrCreate([
|
||||
$this->option['gmod'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'gmod',
|
||||
], [
|
||||
|
@ -280,7 +280,7 @@ EOF;
|
|||
|
||||
private function addInsurgencyVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['insurgency']->id,
|
||||
'env_variable' => 'SRCDS_APPID',
|
||||
], [
|
||||
|
@ -292,7 +292,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^(17705)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['insurgency']->id,
|
||||
'env_variable' => 'SRCDS_GAME',
|
||||
], [
|
||||
|
@ -304,7 +304,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^(insurgency)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['insurgency']->id,
|
||||
'env_variable' => 'SRCDS_MAP',
|
||||
], [
|
||||
|
@ -319,7 +319,7 @@ EOF;
|
|||
|
||||
private function addTF2Variables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['tf2']->id,
|
||||
'env_variable' => 'SRCDS_APPID',
|
||||
], [
|
||||
|
@ -331,7 +331,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^(232250)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['tf2']->id,
|
||||
'env_variable' => 'SRCDS_GAME',
|
||||
], [
|
||||
|
@ -343,7 +343,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^(tf)$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['tf2']->id,
|
||||
'env_variable' => 'SRCDS_MAP',
|
||||
], [
|
||||
|
@ -358,7 +358,7 @@ EOF;
|
|||
|
||||
private function addArkVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['ark']->id,
|
||||
'env_variable' => 'ARK_PASSWORD',
|
||||
], [
|
||||
|
@ -370,7 +370,7 @@ EOF;
|
|||
'rules' => 'alpha_dash|between:1,100',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['ark']->id,
|
||||
'env_variable' => 'ARK_ADMIN_PASSWORD',
|
||||
], [
|
||||
|
@ -382,7 +382,7 @@ EOF;
|
|||
'rules' => 'alpha_dash|between:1,100',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['ark']->id,
|
||||
'env_variable' => 'SERVER_MAX_PLAYERS',
|
||||
], [
|
||||
|
@ -397,7 +397,7 @@ EOF;
|
|||
|
||||
private function addCSGOVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['csgo']->id,
|
||||
'env_variable' => 'SRCDS_MAP',
|
||||
], [
|
||||
|
@ -409,7 +409,7 @@ EOF;
|
|||
'rules' => 'required|string|alpha_dash',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['csgo']->id,
|
||||
'env_variable' => 'STEAM_ACC',
|
||||
], [
|
||||
|
@ -424,7 +424,7 @@ EOF;
|
|||
|
||||
private function addGMODVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['gmod']->id,
|
||||
'env_variable' => 'SRCDS_MAP',
|
||||
], [
|
||||
|
@ -436,7 +436,7 @@ EOF;
|
|||
'rules' => 'required|string|alpha_dash',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['gmod']->id,
|
||||
'env_variable' => 'STEAM_ACC',
|
||||
], [
|
||||
|
@ -451,7 +451,7 @@ EOF;
|
|||
|
||||
private function addCustomVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['source']->id,
|
||||
'env_variable' => 'SRCDS_APPID',
|
||||
], [
|
||||
|
@ -463,7 +463,7 @@ EOF;
|
|||
'rules' => 'required|numeric|digits_between:1,6',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['source']->id,
|
||||
'env_variable' => 'SRCDS_GAME',
|
||||
], [
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Egg;
|
||||
use Pterodactyl\Models\Nest;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
use Pterodactyl\Traits\Services\CreatesServiceIndex;
|
||||
|
||||
class TerrariaServiceTableSeeder extends Seeder
|
||||
|
@ -42,7 +42,7 @@ class TerrariaServiceTableSeeder extends Seeder
|
|||
|
||||
private function addCoreService()
|
||||
{
|
||||
$this->service = Service::updateOrCreate([
|
||||
$this->service = Nest::updateOrCreate([
|
||||
'author' => config('pterodactyl.service.core'),
|
||||
'folder' => 'terraria',
|
||||
], [
|
||||
|
@ -70,7 +70,7 @@ curl -sSLO https://github.com/NyxStudios/TShock/releases/download/v${T_VERSION}/
|
|||
unzip -o tshock_${T_VERSION}.zip -d /mnt/server
|
||||
EOF;
|
||||
|
||||
$this->option['tshock'] = ServiceOption::updateOrCreate([
|
||||
$this->option['tshock'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'tshock',
|
||||
], [
|
||||
|
@ -89,7 +89,7 @@ EOF;
|
|||
|
||||
private function addVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['tshock']->id,
|
||||
'env_variable' => 'T_VERSION',
|
||||
], [
|
||||
|
@ -101,7 +101,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^([0-9_\.-]{5,10})$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['tshock']->id,
|
||||
'env_variable' => 'MAX_SLOTS',
|
||||
], [
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
* This software is licensed under the terms of the MIT license.
|
||||
* https://opensource.org/licenses/MIT
|
||||
*/
|
||||
use Pterodactyl\Models\Egg;
|
||||
use Pterodactyl\Models\Nest;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Pterodactyl\Models\Service;
|
||||
use Pterodactyl\Models\ServiceOption;
|
||||
use Pterodactyl\Models\ServiceVariable;
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
use Pterodactyl\Traits\Services\CreatesServiceIndex;
|
||||
|
||||
class VoiceServiceTableSeeder extends Seeder
|
||||
|
@ -19,7 +19,7 @@ class VoiceServiceTableSeeder extends Seeder
|
|||
/**
|
||||
* The core service ID.
|
||||
*
|
||||
* @var Service
|
||||
* @var Nest
|
||||
*/
|
||||
protected $service;
|
||||
|
||||
|
@ -42,7 +42,7 @@ class VoiceServiceTableSeeder extends Seeder
|
|||
|
||||
private function addCoreService()
|
||||
{
|
||||
$this->service = Service::updateOrCreate([
|
||||
$this->service = Nest::updateOrCreate([
|
||||
'author' => config('pterodactyl.service.core'),
|
||||
'folder' => 'voice',
|
||||
], [
|
||||
|
@ -71,7 +71,7 @@ tar -xjvf murmur-static_x86-${MUMBLE_VERSION}.tar.bz2
|
|||
cp -r murmur-static_x86-${MUMBLE_VERSION}/* /mnt/server
|
||||
EOF;
|
||||
|
||||
$this->option['mumble'] = ServiceOption::updateOrCreate([
|
||||
$this->option['mumble'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'mumble',
|
||||
], [
|
||||
|
@ -124,7 +124,7 @@ logappend=0
|
|||
query_skipbruteforcecheck=0" > /mnt/server/ts3server.ini
|
||||
EOF;
|
||||
|
||||
$this->option['ts3'] = ServiceOption::updateOrCreate([
|
||||
$this->option['ts3'] = Egg::updateOrCreate([
|
||||
'service_id' => $this->service->id,
|
||||
'tag' => 'ts3',
|
||||
], [
|
||||
|
@ -143,7 +143,7 @@ EOF;
|
|||
|
||||
private function addVariables()
|
||||
{
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['mumble']->id,
|
||||
'env_variable' => 'MAX_USERS',
|
||||
], [
|
||||
|
@ -155,7 +155,7 @@ EOF;
|
|||
'rules' => 'required|numeric|digits_between:1,5',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['mumble']->id,
|
||||
'env_variable' => 'MUMBLE_VERSION',
|
||||
], [
|
||||
|
@ -167,7 +167,7 @@ EOF;
|
|||
'rules' => 'required|regex:/^([0-9_\.-]{5,8})$/',
|
||||
]);
|
||||
|
||||
ServiceVariable::updateOrCreate([
|
||||
EggVariable::updateOrCreate([
|
||||
'option_id' => $this->option['ts3']->id,
|
||||
'env_variable' => 'TS_VERSION',
|
||||
], [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue