v1

package
v0.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2019 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package v1 is the v1 version of the API. +groupName=akash.network

Index

Constants

View Source
const (
	CRDPlural   string = "manifests"
	CRDGroup    string = "akash.network"
	CRDVersion  string = "v1"
	FullCRDName string = CRDPlural + "." + CRDGroup
)

Variables

View Source
var (
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: CRDGroup, Version: CRDVersion}

Create a Rest client with the new CRD Schema

Functions

func CreateCRD

func CreateCRD(clientset apiextcs.Interface) error

Create the CRD resource, ignore error if it already exists

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

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 {
	metav1.TypeMeta `json:",inline"`
	// deployment address
	Deployment []byte `protobuf:"bytes,1,opt,name=deployment,proto3,customtype=github.com/ovrclk/akash/types/base.Bytes" json:"deployment"`
	// deployment group sequence
	Group uint64 `protobuf:"varint,2,opt,name=group,proto3" json:"group,omitempty"`
	// order sequence
	Order uint64 `protobuf:"varint,3,opt,name=order,proto3" json:"order,omitempty"`
	// provider address
	Provider []byte `protobuf:"bytes,4,opt,name=provider,proto3,customtype=github.com/ovrclk/akash/types/base.Bytes" json:"provider"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func LeaseIDFromAkash added in v0.3.0

func LeaseIDFromAkash(id types.LeaseID) LeaseID

func (*LeaseID) DeepCopy

func (in *LeaseID) DeepCopy() *LeaseID

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaseID.

func (*LeaseID) DeepCopyInto

func (in *LeaseID) DeepCopyInto(out *LeaseID)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LeaseID) DeepCopyObject

func (in *LeaseID) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (LeaseID) ToAkash added in v0.3.0

func (id LeaseID) ToAkash() types.LeaseID

type Manifest

type Manifest struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`
	Spec              ManifestSpec
	Status            ManifestStatus
}

func NewManifest

func NewManifest(name string, lid types.LeaseID, mgroup *types.ManifestGroup) (*Manifest, error)

func (*Manifest) DeepCopy

func (in *Manifest) DeepCopy() *Manifest

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Manifest.

func (*Manifest) DeepCopyInto

func (in *Manifest) DeepCopyInto(out *Manifest)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Manifest) DeepCopyObject

func (in *Manifest) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Manifest) LeaseID

func (m Manifest) LeaseID() types.LeaseID

func (Manifest) ManifestGroup

func (m Manifest) ManifestGroup() *types.ManifestGroup

type ManifestGroup

type ManifestGroup struct {
	metav1.TypeMeta `json:",inline"`
	// Placement profile name
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Service definitions
	Services []*ManifestService `protobuf:"bytes,2,rep,name=services" json:"services,omitempty"`
}

func ManifestGroupFromAkash added in v0.3.0

func ManifestGroupFromAkash(m *types.ManifestGroup) ManifestGroup

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.

func (*ManifestGroup) DeepCopyObject

func (in *ManifestGroup) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (ManifestGroup) ToAkash added in v0.3.0

func (m ManifestGroup) ToAkash() *types.ManifestGroup

type ManifestList

type ManifestList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:",inline"`
	Items           []Manifest `json:"items"`
}

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 `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Docker image
	Image string   `protobuf:"bytes,2,opt,name=image,proto3" json:"image,omitempty"`
	Args  []string `protobuf:"bytes,3,rep,name=args" json:"args,omitempty"`
	Env   []string `protobuf:"bytes,4,rep,name=env" json:"env,omitempty"`
	// Resource requirements
	Unit ResourceUnit `protobuf:"bytes,5,opt,name=unit" json:"unit"`
	// Number of instances
	Count uint32 `protobuf:"varint,6,opt,name=count,proto3" json:"count,omitempty"`
	// Overlay Network Links
	Expose []*ManifestServiceExpose `protobuf:"bytes,7,rep,name=expose" json:"expose,omitempty"`
}

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         uint32 `protobuf:"varint,1,opt,name=port,proto3" json:"port,omitempty"`
	ExternalPort uint32 `protobuf:"varint,2,opt,name=externalPort,proto3" json:"externalPort,omitempty"`
	Proto        string `protobuf:"bytes,3,opt,name=proto,proto3" json:"proto,omitempty"`
	Service      string `protobuf:"bytes,4,opt,name=service,proto3" json:"service,omitempty"`
	Global       bool   `protobuf:"varint,5,opt,name=global,proto3" json:"global,omitempty"`
	// accepted hostnames
	Hosts []string `protobuf:"bytes,6,rep,name=hosts" json:"hosts,omitempty"`
}

func (*ManifestServiceExpose) DeepCopy

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 ManifestSpec

type ManifestSpec struct {
	metav1.TypeMeta `json:",inline"`
	LeaseID         LeaseID       `json:"lease_id"`
	ManifestGroup   ManifestGroup `json:"manifest_group"`
}

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.

func (*ManifestSpec) DeepCopyObject

func (in *ManifestSpec) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ManifestStatus

type ManifestStatus struct {
	State   string `json:"state,omitempty"`
	Message string `json:"message,omitempty"`
}

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 ResourceUnit

type ResourceUnit struct {
	CPU    uint32 `protobuf:"varint,1,opt,name=CPU,proto3" json:"CPU,omitempty"`
	Memory uint64 `protobuf:"varint,2,opt,name=memory,proto3" json:"memory,omitempty"`
	Disk   uint64 `protobuf:"varint,3,opt,name=disk,proto3" json:"disk,omitempty"`
}

func (*ResourceUnit) DeepCopy

func (in *ResourceUnit) DeepCopy() *ResourceUnit

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceUnit.

func (*ResourceUnit) DeepCopyInto

func (in *ResourceUnit) DeepCopyInto(out *ResourceUnit)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL