Apply node maintenance mode to servers (#4421)
This commit is contained in:
parent
4032481a4f
commit
032e4f2e31
11 changed files with 29 additions and 5 deletions
|
@ -53,7 +53,7 @@ class AuthenticateServerAccess
|
|||
// Still allow users to get information about their server if it is installing or
|
||||
// being transferred.
|
||||
if (!$request->routeIs('api:client:server.view')) {
|
||||
if ($server->isSuspended() && !$request->routeIs('api:client:server.resources')) {
|
||||
if (($server->isSuspended() || $server->node->isUnderMaintenance()) && !$request->routeIs('api:client:server.resources')) {
|
||||
throw $exception;
|
||||
}
|
||||
if (!$user->root_admin || !$request->routeIs($this->except)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue