misc_pterodactyl-panel/database/migrations/2017_03_05_212803_DeleteServiceExecutableOption.php
Dane Everitt 70db461075
Start push of service changes.
Changes the way service files are stored and allows for much easier
updates in the future that won’t affect custom services.

Also stores more configurations in the database to make life easier for
everyone.
2017-03-10 18:25:12 -05:00

38 lines
1 KiB
PHP

<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class DeleteServiceExecutableOption extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('services', function (Blueprint $table) {
$table->dropColumn('executable');
$table->renameColumn('file', 'folder');
$table->text('description')->nullable()->change();
$table->text('startup')->nullable()->change();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('services', function (Blueprint $table) {
$table->string('executable')->after('folder');
$table->renameColumn('folder', 'file');
$table->text('description')->nullable(false)->change();
$table->text('startup')->nullable(false)->change();
});
}
}