Documentation ¶
Index ¶
- func CheckTemplateAllocationByID(ctx context.Context, templateID, accountID string) (bool, error)
- func CheckTemplateExistsByName(ctx context.Context, templateName, accountID string) (bool, error)
- func Create(w http.ResponseWriter, r *http.Request)
- func Delete(w http.ResponseWriter, r *http.Request)
- func Get(w http.ResponseWriter, r *http.Request)
- func List(w http.ResponseWriter, r *http.Request)
- func RemoveTemplate(ctx context.Context, identifier string, accountID string) error
- func SaveTemplate(ctx context.Context, accountID string, template *InstanceTemplate) error
- type InstanceTemplate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckTemplateAllocationByID ¶ added in v0.2.7
func CheckTemplateExistsByName ¶ added in v0.2.8
func RemoveTemplate ¶
func SaveTemplate ¶
func SaveTemplate(ctx context.Context, accountID string, template *InstanceTemplate) error
Types ¶
type InstanceTemplate ¶
type InstanceTemplate struct { ID string `json:"id"` TemplateName string `json:"template_name"` Package string `json:"package"` ImageID string `json:"image_id"` FirewallEnabled bool `json:"firewall_enabled"` Networks []string `json:"networks"` UserData string `json:"userdata"` MetaData map[string]string `json:"metadata"` Tags map[string]string `json:"tags"` CreatedAt time.Time `json:"created_at"` }
func FindTemplateByID ¶
func FindTemplateByName ¶
func FindTemplates ¶
func FindTemplates(ctx context.Context, accountID string) ([]*InstanceTemplate, error)
func (*InstanceTemplate) ShortID ¶
func (t *InstanceTemplate) ShortID() string
Click to show internal directories.
Click to hide internal directories.