create network if doesn't already exist on server, wip test

This commit is contained in:
2025-04-07 18:24:33 +01:00
parent b2070e052d
commit a5854c7a04
13 changed files with 183 additions and 13 deletions

View File

@@ -18,6 +18,7 @@ class CreateServerRequest extends Request implements HasBody
protected ?string $name = null,
protected ?string $serverType = null,
protected ?string $location = null,
protected ?array $networks = null,
) {}
protected function defaultBody(): array
@@ -27,6 +28,7 @@ class CreateServerRequest extends Request implements HasBody
'name' => $this->name,
'server_type' => $this->serverType,
'location' => $this->location,
'networks' => $this->networks,
'user_data' => file_get_contents(resource_path('scripts/hetzner-cloudinit.yml')),
];
}