mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-13 11:53:45 +02:00
admin(ui): add node configuration page
This commit is contained in:
@@ -14,10 +14,15 @@ class NodeConfigurationController extends ApplicationApiController
|
||||
* to remote machines so long as an API key is provided to the machine to make the request
|
||||
* with, and the node is known.
|
||||
*
|
||||
* @return \Illuminate\Http\JsonResponse
|
||||
* @return string
|
||||
* @throws \Illuminate\Contracts\Container\BindingResolutionException
|
||||
*/
|
||||
public function __invoke(GetNodeRequest $request, Node $node)
|
||||
{
|
||||
if ($request->query('format') === 'yaml') {
|
||||
return $node->getYamlConfiguration();
|
||||
}
|
||||
|
||||
return new JsonResponse($node->getConfiguration());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user