server

package
v0.8.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 21, 2023 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrServerNotFound = errors.New("server not found")

Functions

func GenServerProv

func GenServerProv(data ServerData) string

func NameAvailable

func NameAvailable(name string, e2 *ec2.Client) (available bool, err error)

func WaitUntilRunning

func WaitUntilRunning(ids []string, e2 *ec2.Client) (err error)

Types

type Server

type Server struct {
	Name               string
	Cluster            string
	Id                 string
	Type               string
	PublicDNS          string
	VolumeId           string `json:"volume_id"`
	NetworkInterfaceId string `json:"network_interface_id"`
	// contains filtered or unexported fields
}

func Create

func Create(nodeNum int, nodeNames []string, cluster, system, env, iType, subnet, nerthusUrl, visualeUrl string, image ami.Image, key key.Key, group security.Group, e2 *ec2.Client) (Server, error)

func GetServer

func GetServer(name string, e2 *ec2.Client) (s Server, err error)

func NewServer

func NewServer(name, cluster string, image ami.Image, key key.Key, group security.Group, e2 *ec2.Client) (s Server, err error)

func (*Server) Delete

func (s *Server) Delete(e2 *ec2.Client) (err error)

func (*Server) GetPublicDNS

func (s *Server) GetPublicDNS(e2 *ec2.Client) (publicDNS string, err error)

func (*Server) GetVolumeId

func (s *Server) GetVolumeId(e2 *ec2.Client) (volumeId string, err error)

func (Server) WaitUntilNetworkAvailable

func (s Server) WaitUntilNetworkAvailable(e2 *ec2.Client) (err error)

func (Server) WaitUntilTerminated

func (s Server) WaitUntilTerminated(e2 *ec2.Client) (err error)

type ServerData

type ServerData struct {
	BuriVers  string
	CInfo     map[string]string
	CName     string
	CPorts    map[string]int
	Env       string
	NUrl      string
	Hostname  string
	NodeNames []string
	OS        string
	Arch      string
	ServNum   int
	User      string
	System    string
	VUrl      string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL