Documentation ¶
Index ¶
- Constants
- Variables
- func CloseServerPort(hetznerClient *hcloud.Client, firewallID int, portToClose string) error
- func CreateYoloConfigStorage(yoloConfigDir string, apiToken string, region string) error
- func DetachFirewallFromServer(hetznerClient *hcloud.Client, firewallID int, serverID int) error
- func LookupYoloConfig(yoloConfigDir string, apiToken string, region string) (string, error)
- func OpenServerPort(hetznerClient *hcloud.Client, firewallID int, portToOpen string) error
- func RemoveFirewall(hetznerClient *hcloud.Client, firewallID int) error
- func RemoveNetwork(hetznerClient *hcloud.Client, networkID int) error
- func RemoveSSHKey(hetznerClient *hcloud.Client, sshKeyID int) error
- func RemoveServer(hetznerClient *hcloud.Client, serverID int) error
- func RemoveYoloConfig(yoloConfigDir string, apiToken string, region string) error
- func SaveYoloConfig(yoloConfigDir string, apiToken string, region string, configJSON []byte) error
- func WaitForSSHAvailableInServer(serverPublicIPAddress string, serverSSHPort string) (returnedError error)
- type Firewall
- type InitServerScriptResults
- type Location
- type Network
- type RawInitServerScriptResults
- type SSHKey
- type Server
- type ServerTypeInfos
Constants ¶
View Source
const ( ServerSSHPort = 22 ServerRootUser = "root" )
View Source
const (
ServerImage = "ubuntu-22.04"
)
View Source
const YoloConfigFileName = "config.json"
Variables ¶
View Source
var (
ErrInvalidServerType = errors.New("ErrInvalidServerType")
)
View Source
var (
ErrNoYoloConfigFound = errors.New("ErrNoYoloConfigFound")
)
Functions ¶
func CloseServerPort ¶
func CreateYoloConfigStorage ¶
func LookupYoloConfig ¶
func OpenServerPort ¶
func RemoveYoloConfig ¶
func SaveYoloConfig ¶
Types ¶
type Firewall ¶
func CreateFirewall ¶
type InitServerScriptResults ¶
type InitServerScriptResults struct { ExitCode string `json:"exit_code"` SSHHostKeys []entities.EnvSSHHostKey `json:"ssh_host_keys"` }
type Location ¶
type Location struct { ID int `json:"id"` Name string `json:"name"` NetworkZone hcloud.NetworkZone `json:"network_zone"` }
type SSHKey ¶
type Server ¶
type Server struct { ID int `json:"id"` Type string `json:"type"` PublicIPAddress string `json:"tmp_public_ip_address"` InitScriptResults *InitServerScriptResults `json:"init_script_results"` }
type ServerTypeInfos ¶
func LookupServerTypeInfos ¶
Source Files ¶
- close_server_port.go
- create_firewall.go
- create_network.go
- create_server.go
- create_ssh_key.go
- create_yolo_config_storage.go
- detach_firewall.go
- lookup_location.go
- lookup_server_type_infos.go
- lookup_yolo_config.go
- open_server_port.go
- remove_firewall.go
- remove_network.go
- remove_server.go
- remove_ssh_key.go
- remove_yolo_config.go
- save_yolo_config.go
- server_ssh.go
Click to show internal directories.
Click to hide internal directories.