From e2c8a2fdea93cd7785cee5001b9c3e3b34a1f771 Mon Sep 17 00:00:00 2001 From: Matthew Penner Date: Wed, 13 Jan 2021 10:03:27 -0700 Subject: [PATCH] routes: cleanup files --- routes/admin.php | 8 ++++++++ routes/api-remote.php | 9 ++++++++- routes/auth.php | 6 +++--- routes/base.php | 8 ++++++++ routes/server.php | 15 ++++++++------- 5 files changed, 35 insertions(+), 11 deletions(-) diff --git a/routes/admin.php b/routes/admin.php index e215a12a1..452004be8 100644 --- a/routes/admin.php +++ b/routes/admin.php @@ -2,6 +2,14 @@ use Illuminate\Support\Facades\Route; +/* +|-------------------------------------------------------------------------- +| Admin Routes +|-------------------------------------------------------------------------- +| +| Endpoint: /admin +| +*/ Route::get('/', 'BaseController@index')->name('admin.index')->fallback(); Route::get('/{react}', 'BaseController@index') ->where('react', '.+'); diff --git a/routes/api-remote.php b/routes/api-remote.php index ecbcb1675..f5204990b 100644 --- a/routes/api-remote.php +++ b/routes/api-remote.php @@ -2,7 +2,14 @@ use Illuminate\Support\Facades\Route; -// Routes for the Wings daemon. +/* +|-------------------------------------------------------------------------- +| Wings Remote API Routes +|-------------------------------------------------------------------------- +| +| Endpoint: /api/remote +| +*/ Route::post('/sftp/auth', 'SftpAuthenticationController'); Route::get('/servers', 'Servers\ServerDetailsController@list'); diff --git a/routes/auth.php b/routes/auth.php index 6e579796a..d16089ef8 100644 --- a/routes/auth.php +++ b/routes/auth.php @@ -11,8 +11,8 @@ use Illuminate\Support\Facades\Route; | */ Route::group(['middleware' => 'guest'], function () { - // These routes are defined so that we can continue to reference them programatically. - // They all route to the same controller function which passes off to Vuejs. + // These routes are defined so that we can continue to reference them programmatically. + // They all route to the same controller function which passes off to React. Route::get('/login', 'LoginController@index')->name('auth.login'); Route::get('/password', 'LoginController@index')->name('auth.forgot-password'); Route::get('/password/reset/{token}', 'LoginController@index')->name('auth.reset'); @@ -30,7 +30,7 @@ Route::group(['middleware' => 'guest'], function () { // is created). Route::post('/password/reset', 'ResetPasswordController')->name('auth.reset-password'); - // Catch any other combinations of routes and pass them off to the Vuejs component. + // Catch any other combinations of routes and pass them off to the React component. Route::fallback('LoginController@index'); }); diff --git a/routes/base.php b/routes/base.php index c27b24fff..b2b34bdef 100644 --- a/routes/base.php +++ b/routes/base.php @@ -3,6 +3,14 @@ use Illuminate\Support\Facades\Route; use Pterodactyl\Http\Middleware\RequireTwoFactorAuthentication; +/* +|-------------------------------------------------------------------------- +| Base Routes +|-------------------------------------------------------------------------- +| +| Endpoint: / +| +*/ Route::get('/', 'IndexController@index')->name('index')->fallback(); Route::get('/account', 'IndexController@index') ->withoutMiddleware(RequireTwoFactorAuthentication::class) diff --git a/routes/server.php b/routes/server.php index 444a02bc6..07ba6dc48 100644 --- a/routes/server.php +++ b/routes/server.php @@ -2,12 +2,13 @@ use Illuminate\Support\Facades\Route; -/** - * Pterodactyl - Panel - * Copyright (c) 2015 - 2017 Dane Everitt . - * - * This software is licensed under the terms of the MIT license. - * https://opensource.org/licenses/MIT - */ +/* +|-------------------------------------------------------------------------- +| Server Routes +|-------------------------------------------------------------------------- +| +| Endpoint: /server +| +*/ Route::get('/')->name('server.index'); Route::get('/console')->name('server.console');