Documentation ¶
Index ¶
- Variables
- type Manifest
- func (m *Manifest) AddAnnotation(name, value string) error
- func (m *Manifest) AddDependency(imageName types.ACIdentifier, imageId *types.Hash, labels types.Labels, ...) error
- func (m *Manifest) AddEnv(name, value string) error
- func (m *Manifest) AddIsolator(name string, value []byte) error
- func (m *Manifest) AddLabel(name, value string) error
- func (m *Manifest) AddMount(name, path string, readOnly bool) error
- func (m *Manifest) AddPort(name, protocol string, port, count uint, socketActivated bool) error
- func (m *Manifest) Get() *schema.ImageManifest
- func (m *Manifest) GetAnnotations() (map[string]string, error)
- func (m *Manifest) Print(w io.Writer, prettyPrint, printConfig bool) error
- func (m *Manifest) RemoveAnnotation(name string) error
- func (m *Manifest) RemoveDependency(imageName string) error
- func (m *Manifest) RemoveEnv(name string) error
- func (m *Manifest) RemoveIsolator(name string) error
- func (m *Manifest) RemoveLabel(name string) error
- func (m *Manifest) RemoveMount(mount string) error
- func (m *Manifest) RemovePort(port string) error
- func (m *Manifest) Replace(manifestPath string) error
- func (m *Manifest) SetExec(cmd []string) error
- func (m *Manifest) SetGroup(group string) error
- func (m *Manifest) SetName(name string) error
- func (m *Manifest) SetPostStop(exec []string) error
- func (m *Manifest) SetPreStart(exec []string) error
- func (m *Manifest) SetSuppGroups(groups []int) error
- func (m *Manifest) SetTag(value string) error
- func (m *Manifest) SetUser(user string) error
- func (m *Manifest) SetWorkingDir(dir string) error
Constants ¶
This section is empty.
Variables ¶
var ( // ErrNotFound is returned when acbuild is asked to remove an element from a // list and the element is not present in the list ErrNotFound = fmt.Errorf("element to be removed does not exist in this ACI") )
Functions ¶
This section is empty.
Types ¶
type Manifest ¶
type Manifest struct {
// contains filtered or unexported fields
}
Manifest is a struct with an open handle to a manifest that it can manipulate
func LoadManifest ¶
LoadManifest will read in the manifest from an untarred ACI on disk at location aciPath, and return a new Manifest struct to manipulate it.
func (*Manifest) AddAnnotation ¶
AddAnnotation adds an annotation of name and value to the current manifest
func (*Manifest) AddDependency ¶
func (m *Manifest) AddDependency(imageName types.ACIdentifier, imageId *types.Hash, labels types.Labels, size uint) error
AddDependency will add a dependency with the given name, id, labels, and size to the untarred ACI stored at a.CurrentImagePath. If the dependency already exists its fields will be updated to the new values.
func (*Manifest) AddEnv ¶
AddEnv will add an environment variable of name and value to the current manifest
func (*Manifest) AddIsolator ¶
AddIsolator adds an isolator of name and value to the current manifest
func (*Manifest) AddLabel ¶
AddLabel will add a label with the given name and value to the untarred ACI stored at a.CurrentImagePath. If the label already exists its value will be updated to the new value.
func (*Manifest) AddMount ¶
AddMount will add a mount point with the given name and path to the untarred ACI stored at a.CurrentImagePath. If the mount point already exists its value will be updated to the new value. readOnly signifies whether or not the mount point should be read only.
func (*Manifest) AddPort ¶
AddPort will add a port with the given name, protocol, port, and count to the untarred ACI stored at a.CurrentImagePath. If the port already exists its value will be updated to the new value. socketActivated signifies whether or not the application will be socket activated via this port.
func (*Manifest) Get ¶
func (m *Manifest) Get() *schema.ImageManifest
Get returns the manifest currently being manipulated
func (*Manifest) Print ¶
Print will print out the current manifest to stdout, optionally inserting whitespace to improve readability
func (*Manifest) RemoveAnnotation ¶
RemoveAnnotation removes an annotation of name from the current manifest
func (*Manifest) RemoveDependency ¶
RemoveDependency will remove the dependency with the given name from the untarred ACI stored at a.CurrentImagePath.
func (*Manifest) RemoveEnv ¶
Remove Env will remove an environment variable of name from the current manifest
func (*Manifest) RemoveIsolator ¶
RemoveIsolator removes an isolator of name from the current manifest
func (*Manifest) RemoveLabel ¶
RemoveLabel will remove the label with the given name from the untarred ACI stored at a.CurrentImagePath
func (*Manifest) RemoveMount ¶
RemoveMount will remove the mount point with the given name from the untarred ACI stored at a.CurrentImagePath
func (*Manifest) RemovePort ¶
RemovePort will remove the port with the given name from the untarred ACI stored at a.CurrentImagePath.
func (*Manifest) Replace ¶
Replace will replace the manifest in the expanded ACI stored at a.CurrentImagePath with the new manifest stored at manifestPath
func (*Manifest) SetExec ¶
SetExec sets the exec command for the untarred ACI stored at a.CurrentImagePath.
func (*Manifest) SetGroup ¶
SetGroup sets the group the pod will run as in the untarred ACI stored at a.CurrentImagePath.
func (*Manifest) SetPostStop ¶
SetPostStop sets the post-stop event handler in the expanded ACI stored at a.CurrentImagePath
func (*Manifest) SetPreStart ¶
SetPreStart sets the pre-start event handler in the expanded ACI stored at a.CurrentImagePath
func (*Manifest) SetSuppGroups ¶
SetSuppGroups sets the groups the pod will run as in the untarred ACI stored at a.CurrentACIPath.
func (*Manifest) SetUser ¶
SetUser sets the user the pod will run as in the untarred ACI stored at a.CurrentImagePath.
func (*Manifest) SetWorkingDir ¶
SetWorkingDir sets the workingDirectory value in the untarred ACI stored at a.CurrentImagePath