Documentation
¶
Index ¶
Constants ¶
const ( // MountKindOverlay captures enum value "overlay" MountKindOverlay string = "overlay" // MountKindRbd captures enum value "rbd" MountKindRbd string = "rbd" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Container ¶
type Container struct {
// command
// Required: true
Command *string `json:"command"`
// id
ID ID `json:"id,omitempty"`
// logfile
// Read Only: true
Logfile string `json:"logfile,omitempty"`
// mount
// Required: true
Mount *Mount `json:"mount"`
// name is an optional identifier for the container. Name must be unique.
Name Name `json:"name,omitempty"`
// A list of Linux namespaces to use.
//
// Note: This is currently unused. All containers currently get `mnt` and `pid`.
// It's here as a placeholder for future use.
//
Namespaces []ContainerNamespace `json:"namespaces"`
// When read, this contains the current container state. On creation, this requests the initial state (valid options: `created` or `running`). The default is `created`.
//
State ContainerState `json:"state,omitempty"`
// When `systemd` is set to `true`, we will assume that this container will run `systemd`, and perform the necessary magic dance to make systemd run inside of the container. The default is `false`.
//
Systemd bool `json:"systemd,omitempty"`
}
Container The `container` option describes a minimally namespaced container.
A container is identified by a service-provided unique numeric `pid`.
Optionally, a container can be provided with a `name`. The name must be unique. Containers can be referenced by `name` if provided.
swagger:model container
func (*Container) ContextValidate ¶
ContextValidate validate this container based on the context it is used
func (*Container) MarshalBinary ¶
MarshalBinary interface implementation
func (*Container) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type ContainerNamespace ¶
type ContainerNamespace string
ContainerNamespace Linux namespace
swagger:model container_namespace
const ( // ContainerNamespaceCgroup captures enum value "cgroup" ContainerNamespaceCgroup ContainerNamespace = "cgroup" // ContainerNamespaceIpc captures enum value "ipc" ContainerNamespaceIpc ContainerNamespace = "ipc" // ContainerNamespaceNet captures enum value "net" ContainerNamespaceNet ContainerNamespace = "net" // ContainerNamespaceMnt captures enum value "mnt" ContainerNamespaceMnt ContainerNamespace = "mnt" // ContainerNamespacePid captures enum value "pid" ContainerNamespacePid ContainerNamespace = "pid" // ContainerNamespaceTime captures enum value "time" ContainerNamespaceTime ContainerNamespace = "time" // ContainerNamespaceUser captures enum value "user" ContainerNamespaceUser ContainerNamespace = "user" // ContainerNamespaceUts captures enum value "uts" ContainerNamespaceUts ContainerNamespace = "uts" )
func (ContainerNamespace) ContextValidate ¶
ContextValidate validates this container namespace based on context it is used
type ContainerState ¶
type ContainerState string
ContainerState Valid container states
swagger:model container_state
const ( // ContainerStateCreated captures enum value "created" ContainerStateCreated ContainerState = "created" // ContainerStateRunning captures enum value "running" ContainerStateRunning ContainerState = "running" // ContainerStateStopping captures enum value "stopping" ContainerStateStopping ContainerState = "stopping" // ContainerStateExited captures enum value "exited" ContainerStateExited ContainerState = "exited" // ContainerStateDead captures enum value "dead" ContainerStateDead ContainerState = "dead" )
func (ContainerState) ContextValidate ¶
ContextValidate validates this container state based on context it is used
type Error ¶
type Error struct {
// code
Code int64 `json:"code,omitempty"`
// message
// Required: true
Message *string `json:"message"`
}
Error error
swagger:model error
func (*Error) ContextValidate ¶
ContextValidate validates this error based on context it is used
func (*Error) MarshalBinary ¶
MarshalBinary interface implementation
func (*Error) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type ID ¶
type ID int64
ID An ID is a unique numeric ID that references an object. IDs are not necessarily unique across object types. IDs are generall readOnly and generated internally.
swagger:model id
func (ID) ContextValidate ¶
ContextValidate validates this id based on context it is used
type Mount ¶
type Mount struct {
// kind
// Required: true
// Enum: [overlay rbd]
Kind *string `json:"kind"`
// mount id
MountID ID `json:"mount_id,omitempty"`
// overlay
Overlay *MountOverlay `json:"overlay,omitempty"`
// rbd
Rbd *MountRbd `json:"rbd,omitempty"`
}
Mount Generically address mounts by kind and ID or definition Either an `mount_id` or a mount definition must be supplied. If both are supplied, the mount definition will be ignored. If `mount_id` is specified, then the kind/id will be used to reference that mount. If no `mount_id` is supplied a defition of type `kind` must be present.
swagger:model mount
func (*Mount) ContextValidate ¶
ContextValidate validate this mount based on the context it is used
func (*Mount) MarshalBinary ¶
MarshalBinary interface implementation
func (*Mount) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type MountOverlay ¶
type MountOverlay struct {
// id
// Read Only: true
ID ID `json:"id,omitempty"`
// This is an array of mount specifications to be used (in order) as lower mounts for the overlay.
// Required: true
Lower []*Mount `json:"lower"`
// mountpoint
// Read Only: true
Mountpoint string `json:"mountpoint,omitempty"`
// refs
// Read Only: true
Refs int64 `json:"refs,omitempty"`
// currently, upperdir is always a directory in mountDir
// Read Only: true
Upperdir string `json:"upperdir,omitempty"`
// workdir
// Read Only: true
Workdir string `json:"workdir,omitempty"`
}
MountOverlay `mount_overlay` describes an Overlayfs mount. All mount points must be RBD ID's. At very least, `lower` must be specified. If `upper` length is zero, no `upper` mounts will be used. `workdir` will be assigned automatically.
If the mounts specified in `lower` are specifications and not ID references, they will be recursively mounted/attached.
Overlay mounts are identified by their uppermost `lower` ID.
swagger:model mount_overlay
func (*MountOverlay) ContextValidate ¶
ContextValidate validate this mount overlay based on the context it is used
func (*MountOverlay) MarshalBinary ¶
func (m *MountOverlay) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*MountOverlay) UnmarshalBinary ¶
func (m *MountOverlay) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type MountRbd ¶
type MountRbd struct {
// fs type
// Required: true
FsType *string `json:"fs_type"`
// id
// Read Only: true
ID ID `json:"id,omitempty"`
// mount options
MountOptions []string `json:"mount_options"`
// mountpoint
// Read Only: true
Mountpoint string `json:"mountpoint,omitempty"`
// rbd
Rbd *Rbd `json:"rbd,omitempty"`
// rbd id
RbdID ID `json:"rbd_id,omitempty"`
// refs
// Read Only: true
Refs int64 `json:"refs,omitempty"`
}
MountRbd mount_rbd describes an RBD mount. This must have at least and RBD ID associated with it (which becomes the mount's ID), and a provided filesystem type.
Either `rbd_id` or `rbd` must be specified. If both are specified, `rbd` will be ignored.
If `rbd` is specified and `rbd_id` is omitted, the RBD will first be attached, and will be detached on deletion.
swagger:model mount_rbd
func (*MountRbd) ContextValidate ¶
ContextValidate validate this mount rbd based on the context it is used
func (*MountRbd) MarshalBinary ¶
MarshalBinary interface implementation
func (*MountRbd) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type Name ¶
type Name string
Name A name is a unique, user-provided identifier for an object.
A name must consist of numbers, letters, and the symbols in the set { `.`, `-`, `_`}.
swagger:model name
func (Name) ContextValidate ¶
ContextValidate validates this name based on context it is used
type Rbd ¶
type Rbd struct {
// The device_file is the path to the system device file.
// Read Only: true
DeviceFile string `json:"device_file,omitempty"`
// The dev_id is the device ID in the rbd subsystem.
// Read Only: true
DeviceID int64 `json:"device_id,omitempty"`
// id
ID ID `json:"id,omitempty"`
// image
// Required: true
// Min Length: 1
Image *string `json:"image"`
// monitors
// Required: true
Monitors []strfmt.IPv4 `json:"monitors"`
// options
Options *RbdOptions `json:"options,omitempty"`
// pool
// Required: true
// Min Length: 1
Pool *string `json:"pool"`
// refs
// Read Only: true
Refs int64 `json:"refs,omitempty"`
// snapshot
Snapshot string `json:"snapshot,omitempty"`
}
Rbd rbd describes an RBD map. To successfully map, at least one monitor, pool and image must be specified. Additionally, you will need options.name and options.secret specified.
swagger:model rbd
func (*Rbd) ContextValidate ¶
ContextValidate validate this rbd based on the context it is used
func (*Rbd) MarshalBinary ¶
MarshalBinary interface implementation
func (*Rbd) UnmarshalBinary ¶
UnmarshalBinary interface implementation
type RbdOptions ¶
type RbdOptions struct {
// abort on full
AbortOnFull bool `json:"abort_on_full,omitempty"`
// alloc size
AllocSize int64 `json:"alloc_size,omitempty"`
// ceph requires signatures
CephRequiresSignatures bool `json:"ceph_requires_signatures,omitempty"`
// cephx sign messages
CephxSignMessages bool `json:"cephx_sign_messages,omitempty"`
// crc
Crc bool `json:"crc,omitempty"`
// exclusive
Exclusive bool `json:"exclusive,omitempty"`
// force
Force bool `json:"force,omitempty"`
// fsid
Fsid string `json:"fsid,omitempty"`
// ip
// Pattern: ^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$
// Format: ipv4
IP strfmt.IPv4 `json:"ip,omitempty"`
// lock on read
LockOnRead bool `json:"lock_on_read,omitempty"`
// lock timeout
LockTimeout int64 `json:"lock_timeout,omitempty"`
// mount timeout
MountTimeout int64 `json:"mount_timeout,omitempty"`
// name
Name string `json:"name,omitempty"`
// namespace
Namespace string `json:"namespace,omitempty"`
// noceph requires signatures
NocephRequiresSignatures bool `json:"noceph_requires_signatures,omitempty"`
// nocephx sign messages
NocephxSignMessages bool `json:"nocephx_sign_messages,omitempty"`
// nocrc
Nocrc bool `json:"nocrc,omitempty"`
Noshare bool `json:"noshare,omitempty"`
// notcp nodelay
NotcpNodelay bool `json:"notcp_nodelay,omitempty"`
// notrim
Notrim bool `json:"notrim,omitempty"`
// osd idle ttl
OsdIdleTTL int64 `json:"osd_idle_ttl,omitempty"`
// osdkeepalive
Osdkeepalive int64 `json:"osdkeepalive,omitempty"`
// queue depth
QueueDepth int64 `json:"queue_depth,omitempty"`
// ro
Ro bool `json:"ro,omitempty"`
// rw
Rw bool `json:"rw,omitempty"`
// secret
Secret string `json:"secret,omitempty"`
Share bool `json:"share,omitempty"`
// tcp nodelay
TCPNodelay bool `json:"tcp_nodelay,omitempty"`
}
RbdOptions rbd options
swagger:model rbd_options
func (*RbdOptions) ContextValidate ¶
ContextValidate validates this rbd options based on context it is used
func (*RbdOptions) MarshalBinary ¶
func (m *RbdOptions) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RbdOptions) UnmarshalBinary ¶
func (m *RbdOptions) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation