Show console when an admin is viewing an installing server
This commit is contained in:
parent
446dc8b33d
commit
6056b6f45d
4 changed files with 130 additions and 88 deletions
|
@ -11,17 +11,17 @@ use Pterodactyl\Http\Middleware\Api\Client\Server\AuthenticateServerAccess;
|
|||
| Endpoint: /api/client
|
||||
|
|
||||
*/
|
||||
Route::get('/', 'ClientController@index')->name('api.client.index');
|
||||
Route::get('/', 'ClientController@index')->name('api:client.index');
|
||||
Route::get('/permissions', 'ClientController@permissions');
|
||||
|
||||
Route::group(['prefix' => '/account'], function () {
|
||||
Route::get('/', 'AccountController@index')->name('api.client.account');
|
||||
Route::get('/', 'AccountController@index')->name('api:client.account');
|
||||
Route::get('/two-factor', 'TwoFactorController@index');
|
||||
Route::post('/two-factor', 'TwoFactorController@store');
|
||||
Route::delete('/two-factor', 'TwoFactorController@delete');
|
||||
|
||||
Route::put('/email', 'AccountController@updateEmail')->name('api.client.account.update-email');
|
||||
Route::put('/password', 'AccountController@updatePassword')->name('api.client.account.update-password');
|
||||
Route::put('/email', 'AccountController@updateEmail')->name('api:client.account.update-email');
|
||||
Route::put('/password', 'AccountController@updatePassword')->name('api:client.account.update-password');
|
||||
|
||||
Route::get('/api-keys', 'ApiKeyController@index');
|
||||
Route::post('/api-keys', 'ApiKeyController@store');
|
||||
|
@ -37,30 +37,29 @@ Route::group(['prefix' => '/account'], function () {
|
|||
|
|
||||
*/
|
||||
Route::group(['prefix' => '/servers/{server}', 'middleware' => [AuthenticateServerAccess::class]], function () {
|
||||
Route::get('/', 'Servers\ServerController@index')->name('api.client.servers.view');
|
||||
Route::get('/websocket', 'Servers\WebsocketController')->name('api.client.servers.websocket');
|
||||
Route::get('/resources', 'Servers\ResourceUtilizationController')
|
||||
->name('api.client.servers.resources');
|
||||
Route::get('/', 'Servers\ServerController@index')->name('api:client:server.view');
|
||||
Route::get('/websocket', 'Servers\WebsocketController')->name('api:client:server.ws');
|
||||
Route::get('/resources', 'Servers\ResourceUtilizationController')->name('api:client:server.resources');
|
||||
|
||||
Route::post('/command', 'Servers\CommandController@index')->name('api.client.servers.command');
|
||||
Route::post('/power', 'Servers\PowerController@index')->name('api.client.servers.power');
|
||||
Route::post('/command', 'Servers\CommandController@index');
|
||||
Route::post('/power', 'Servers\PowerController@index');
|
||||
|
||||
Route::group(['prefix' => '/databases'], function () {
|
||||
Route::get('/', 'Servers\DatabaseController@index')->name('api.client.servers.databases');
|
||||
Route::get('/', 'Servers\DatabaseController@index');
|
||||
Route::post('/', 'Servers\DatabaseController@store');
|
||||
Route::post('/{database}/rotate-password', 'Servers\DatabaseController@rotatePassword');
|
||||
Route::delete('/{database}', 'Servers\DatabaseController@delete')->name('api.client.servers.databases.delete');
|
||||
Route::delete('/{database}', 'Servers\DatabaseController@delete');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => '/files'], function () {
|
||||
Route::get('/list', 'Servers\FileController@listDirectory')->name('api.client.servers.files.list');
|
||||
Route::get('/contents', 'Servers\FileController@getFileContents')->name('api.client.servers.files.contents');
|
||||
Route::get('/list', 'Servers\FileController@listDirectory');
|
||||
Route::get('/contents', 'Servers\FileController@getFileContents');
|
||||
Route::get('/download', 'Servers\FileController@download');
|
||||
Route::put('/rename', 'Servers\FileController@renameFile')->name('api.client.servers.files.rename');
|
||||
Route::post('/copy', 'Servers\FileController@copyFile')->name('api.client.servers.files.copy');
|
||||
Route::post('/write', 'Servers\FileController@writeFileContents')->name('api.client.servers.files.write');
|
||||
Route::post('/delete', 'Servers\FileController@delete')->name('api.client.servers.files.delete');
|
||||
Route::post('/create-folder', 'Servers\FileController@createFolder')->name('api.client.servers.files.create-folder');
|
||||
Route::put('/rename', 'Servers\FileController@renameFile');
|
||||
Route::post('/copy', 'Servers\FileController@copyFile');
|
||||
Route::post('/write', 'Servers\FileController@writeFileContents');
|
||||
Route::post('/delete', 'Servers\FileController@delete');
|
||||
Route::post('/create-folder', 'Servers\FileController@createFolder');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => '/schedules'], function () {
|
||||
|
@ -76,7 +75,7 @@ Route::group(['prefix' => '/servers/{server}', 'middleware' => [AuthenticateServ
|
|||
});
|
||||
|
||||
Route::group(['prefix' => '/network'], function () {
|
||||
Route::get('/', 'Servers\NetworkController@index')->name('api.client.servers.network');
|
||||
Route::get('/', 'Servers\NetworkController@index');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => '/users'], function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue