id(); $table->string("name"); $table->string("public_key"); $table->string("ip")->nullable(); $table->string("allowed_ips")->nullable(); $table->string("preshared_key")->nullable(); $table->boolean("imported")->default(false); $table->unsignedBigInteger("user_id")->nullable(); $table->unsignedBigInteger("vpn_id"); $table->timestamps(); $table->foreign('user_id')->references('id')->on('users'); $table->foreign('vpn_id')->references('id')->on('vpns'); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('peers'); } }