Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
pterodactyl
GitHub Repository: pterodactyl/panel
Path: blob/1.0-develop/database/migrations/2016_02_07_172148_add_databases_tables.php
7460 views
1
<?php
2
3
use Illuminate\Support\Facades\Schema;
4
use Illuminate\Database\Schema\Blueprint;
5
use Illuminate\Database\Migrations\Migration;
6
7
class AddDatabasesTables extends Migration
8
{
9
/**
10
* Run the migrations.
11
*/
12
public function up(): void
13
{
14
Schema::create('databases', function (Blueprint $table) {
15
$table->increments('id');
16
$table->integer('server')->unsigned();
17
$table->integer('db_server')->unsigned();
18
$table->string('database')->unique();
19
$table->string('username')->unique();
20
$table->string('remote')->default('%');
21
$table->text('password');
22
$table->timestamps();
23
});
24
}
25
26
/**
27
* Reverse the migrations.
28
*/
29
public function down(): void
30
{
31
Schema::drop('databases');
32
}
33
}
34
35