| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- <?php
- use Illuminate\Support\Facades\Schema;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Database\Migrations\Migration;
- class CreateSsNodeTable extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('ss_node', function (Blueprint $table) {
- $table->engine = 'InnoDB';
- $table->increments('id');
- $table->string('name', 128)->comment('名称');
- $table->integer('group_id')->default('0')->comment('所属分组');
- $table->char('country_code', 5)->comment('国家代码');
- $table->string('server', 128)->comment('服务器地址');
- $table->string('desc', 255)->comment('节点简单描述');
- $table->string('method', 30)->default('aes-192-ctr')->comment('加密方式');
- $table->string('custom_method', 30)->default('aes-192-ctr')->comment('自定义加密方式');
- $table->string('protocol', 128)->default('auth_chain_a')->comment('协议');
- $table->string('protocol_param', 128)->comment('协议参数');
- $table->string('obfs', 128)->default('tls1.2_ticket_auth')->comment('混淆');
- $table->string('obfs_param', 128)->comment('混淆参数');
- $table->float('traffic_rate')->default('1')->comment('流量比率');
- $table->integer('bandwidth')->default('100')->comment('出口带宽,单位M');
- $table->bigInteger('traffic')->default('1000')->comment('每月可用流量,单位G');
- $table->string('monitor_url', 255)->comment('监控地址');
- $table->tinyInteger('compatible')->default('0')->comment('兼容SS');
- $table->tinyInteger('single')->default('0')->comment('单端口多用户');
- $table->tinyInteger('single_force')->comment('模式:0-兼容模式、1-严格模式');
- $table->string('single_port', 50)->comment('端口号,用,号分隔');
- $table->string('single_passwd', 50)->comment('密码');
- $table->string('single_method', 128)->comment('加密方式');
- $table->string('single_protocol', 128)->comment('协议');
- $table->string('single_obfs', 128)->comment('混淆');
- $table->integer('sort')->default('0')->comment('排序值,值越大越靠前显示');
- $table->tinyInteger('status')->default('1')->comment('状态:0-维护、1-正常');
- $table->dateTime('created_at')->nullable();
- $table->dateTime('updated_at')->nullable();
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('ss_node');
- }
- }
|