Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RemoveSavedTemplateConfig ¶
Removes all the state associated with the template with given ID If there is no state associated with this ID then the function simply returns without doing anything.
func SaveTemplateConfig ¶
func SaveTemplateConfig(ctx context.Context, templateConfig *TemplateConfig) error
Saves all the information required to create a clone from the template of this container into the registry.
Types ¶
type TemplateConfig ¶
type TemplateConfig struct { SerialVersionID uint32 TemplateUVMID string TemplateUVMResources []uvm.Cloneable TemplateUVMCreateOpts uvm.OptionsWCOW TemplateContainerID string // Below we store the container spec for the template container so that when // cloning containers we can verify that a different spec is not provided for the // cloned container. TemplateContainerSpec specs.Spec }
TemplateConfig struct maintains all of the information about a template. This includes the information for both the template container and the template UVM. This struct is serialized and stored in the registry and hence is version controlled. Note: Update the `templateConfigCurrentSerialVersionID` when this structure definition is changed.
func FetchTemplateConfig ¶
func FetchTemplateConfig(ctx context.Context, id string) (*TemplateConfig, error)
Retrieves the UVMTemplateConfig for the template with given ID from the registry.