Documentation ¶
Overview ¶
Package v1 is the initial version of types which integrate with the Kubernetes API.
Contains the Stack Definition Language(pkg: github.com/ovrclk/akash/sdl) Manifest declarations which are written to Kubernetes CRDs for storage.
Manifest { ManifestSpec { k8s.TypeMeta LeaseID ManifestGroup k8s.TypeMeta Name []*ManifestService ManifestService analogous to a running container. ManifestStatus State Message }
Index ¶
- Variables
- func Resource(resource string) schema.GroupResource
- type LeaseID
- type Manifest
- type ManifestGroup
- type ManifestList
- type ManifestService
- type ManifestServiceExpose
- type ManifestServiceExposeHTTPOptions
- type ManifestSpec
- type ManifestStatus
- type ProviderHost
- type ProviderHostList
- type ProviderHostSpec
- type ProviderHostStatus
- type ResourceUnits
Constants ¶
This section is empty.
Variables ¶
var ( // AddToScheme applies all the stored functions to the scheme AddToScheme = schemeBuilder.AddToScheme // SchemeGroupVersion creates a Rest client with the new CRD Schema SchemeGroupVersion = schema.GroupVersion{Group: crdGroup, Version: crdVersion} )
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type LeaseID ¶
type LeaseID struct { Owner string `json:"owner"` DSeq string `json:"dseq"` GSeq uint32 `json:"gseq"` OSeq uint32 `json:"oseq"` Provider string `json:"provider"` }
LeaseID stores deployment, group sequence, order, provider and metadata
func (*LeaseID) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaseID.
func (*LeaseID) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Manifest ¶
type Manifest struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata"` Spec ManifestSpec `json:"spec,omitempty"` Status ManifestStatus `json:"status,omitempty"` }
Manifest store metadata, specifications and status of the Lease
func NewManifest ¶
NewManifest creates new manifest with provided details. Returns error incase of failure.
func (*Manifest) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Manifest.
func (*Manifest) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Manifest) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (Manifest) Deployment ¶ added in v0.7.3
func (m Manifest) Deployment() (ctypes.Deployment, error)
Deployment returns the cluster.Deployment that the saved manifest represents.
type ManifestGroup ¶
type ManifestGroup struct { // Placement profile name Name string `json:"name,omitempty"` // Service definitions Services []ManifestService `json:"services,omitempty"` }
ManifestGroup stores metadata, name and list of SDL manifest services
func (*ManifestGroup) DeepCopy ¶
func (in *ManifestGroup) DeepCopy() *ManifestGroup
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestGroup.
func (*ManifestGroup) DeepCopyInto ¶
func (in *ManifestGroup) DeepCopyInto(out *ManifestGroup)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestList ¶
type ManifestList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []Manifest `json:"items"` }
ManifestList stores metadata and items list of manifest
func (*ManifestList) DeepCopy ¶
func (in *ManifestList) DeepCopy() *ManifestList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestList.
func (*ManifestList) DeepCopyInto ¶
func (in *ManifestList) DeepCopyInto(out *ManifestList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ManifestList) DeepCopyObject ¶
func (in *ManifestList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ManifestService ¶
type ManifestService struct { // Service name Name string `json:"name,omitempty"` // Docker image Image string `json:"image,omitempty"` Args []string `json:"args,omitempty"` Env []string `json:"env,omitempty"` // Resource requirements // in current version of CRD it is named as unit Resources ResourceUnits `json:"unit"` // Number of instances Count uint32 `json:"count,omitempty"` // Overlay Network Links Expose []ManifestServiceExpose `json:"expose,omitempty"` }
ManifestService stores name, image, args, env, unit, count and expose list of service
func (*ManifestService) DeepCopy ¶
func (in *ManifestService) DeepCopy() *ManifestService
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestService.
func (*ManifestService) DeepCopyInto ¶
func (in *ManifestService) DeepCopyInto(out *ManifestService)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestServiceExpose ¶
type ManifestServiceExpose struct { Port uint16 `json:"port,omitempty"` ExternalPort uint16 `json:"external_port,omitempty"` Proto string `json:"proto,omitempty"` Service string `json:"service,omitempty"` Global bool `json:"global,omitempty"` // accepted hostnames Hosts []string `json:"hosts,omitempty"` HTTPOptions ManifestServiceExposeHTTPOptions `json:"http_options,omitempty"` }
ManifestServiceExpose stores exposed ports and accepted hosts details
func (*ManifestServiceExpose) DeepCopy ¶
func (in *ManifestServiceExpose) DeepCopy() *ManifestServiceExpose
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestServiceExpose.
func (*ManifestServiceExpose) DeepCopyInto ¶
func (in *ManifestServiceExpose) DeepCopyInto(out *ManifestServiceExpose)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestServiceExposeHTTPOptions ¶ added in v0.14.0
type ManifestServiceExposeHTTPOptions struct { MaxBodySize uint32 `json:"max_body_size,omitempty"` ReadTimeout uint32 `json:"read_timeout,omitempty"` SendTimeout uint32 `json:"send_timeout,omitempty"` NextTries uint32 `json:"next_tries,omitempty"` NextTimeout uint32 `json:"next_timeout,omitempty"` NextCases []string `json:"next_cases,omitempty"` }
func (*ManifestServiceExposeHTTPOptions) DeepCopy ¶ added in v0.16.0
func (in *ManifestServiceExposeHTTPOptions) DeepCopy() *ManifestServiceExposeHTTPOptions
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestServiceExposeHTTPOptions.
func (*ManifestServiceExposeHTTPOptions) DeepCopyInto ¶ added in v0.16.0
func (in *ManifestServiceExposeHTTPOptions) DeepCopyInto(out *ManifestServiceExposeHTTPOptions)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestSpec ¶
type ManifestSpec struct { LeaseID LeaseID `json:"lease_id"` Group ManifestGroup `json:"group"` }
ManifestSpec stores LeaseID, Group and metadata details
func (*ManifestSpec) DeepCopy ¶
func (in *ManifestSpec) DeepCopy() *ManifestSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestSpec.
func (*ManifestSpec) DeepCopyInto ¶
func (in *ManifestSpec) DeepCopyInto(out *ManifestSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestStatus ¶
type ManifestStatus struct { State string `json:"state,omitempty"` Message string `json:"message,omitempty"` }
ManifestStatus stores state and message of manifest
func (*ManifestStatus) DeepCopy ¶
func (in *ManifestStatus) DeepCopy() *ManifestStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestStatus.
func (*ManifestStatus) DeepCopyInto ¶
func (in *ManifestStatus) DeepCopyInto(out *ManifestStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProviderHost ¶ added in v0.14.0
type ProviderHost struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata"` Spec ProviderHostSpec `json:"spec,omitempty"` Status ProviderHostStatus `json:"status,omitempty"` }
func (*ProviderHost) DeepCopy ¶ added in v0.14.0
func (in *ProviderHost) DeepCopy() *ProviderHost
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderHost.
func (*ProviderHost) DeepCopyInto ¶ added in v0.14.0
func (in *ProviderHost) DeepCopyInto(out *ProviderHost)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ProviderHost) DeepCopyObject ¶ added in v0.14.0
func (in *ProviderHost) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ProviderHostList ¶ added in v0.14.0
type ProviderHostList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []ProviderHost `json:"items"` }
func (*ProviderHostList) DeepCopy ¶ added in v0.14.0
func (in *ProviderHostList) DeepCopy() *ProviderHostList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderHostList.
func (*ProviderHostList) DeepCopyInto ¶ added in v0.14.0
func (in *ProviderHostList) DeepCopyInto(out *ProviderHostList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ProviderHostList) DeepCopyObject ¶ added in v0.14.0
func (in *ProviderHostList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ProviderHostSpec ¶ added in v0.14.0
type ProviderHostSpec struct { Owner string `json:"owner"` Provider string `json:"provider"` Hostname string `json:"hostname"` Dseq uint64 `json:"dseq"` Gseq uint32 `json:"gseq"` Oseq uint32 `json:"oseq"` ServiceName string `json:"service_name"` ExternalPort uint32 `json:"external_port"` }
func (*ProviderHostSpec) DeepCopy ¶ added in v0.14.0
func (in *ProviderHostSpec) DeepCopy() *ProviderHostSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderHostSpec.
func (*ProviderHostSpec) DeepCopyInto ¶ added in v0.14.0
func (in *ProviderHostSpec) DeepCopyInto(out *ProviderHostSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ProviderHostStatus ¶ added in v0.14.0
type ProviderHostStatus struct { State string `json:"state,omitempty"` Message string `json:"message,omitempty"` }
func (*ProviderHostStatus) DeepCopy ¶ added in v0.14.0
func (in *ProviderHostStatus) DeepCopy() *ProviderHostStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProviderHostStatus.
func (*ProviderHostStatus) DeepCopyInto ¶ added in v0.14.0
func (in *ProviderHostStatus) DeepCopyInto(out *ProviderHostStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ResourceUnits ¶ added in v0.9.1
type ResourceUnits struct { CPU uint32 `json:"cpu,omitempty"` Memory string `json:"memory,omitempty"` Storage string `json:"storage,omitempty"` }
ResourceUnits stores cpu, memory and storage details
func (*ResourceUnits) DeepCopy ¶ added in v0.9.1
func (in *ResourceUnits) DeepCopy() *ResourceUnits
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceUnits.
func (*ResourceUnits) DeepCopyInto ¶ added in v0.9.1
func (in *ResourceUnits) DeepCopyInto(out *ResourceUnits)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.