Documentation ¶
Index ¶
- Constants
- func ApplyObject(ctx context.Context, cli client.Client, obj client.Object) error
- func CreateOrUpdateContainer(inpod *corev1.PodSpec, conname string, ...) *corev1.PodSpec
- func IsOwnBy(obj client.Object, gvk schema.GroupVersionKind) bool
- func Mergekvs(kvs map[string]string, into map[string]string) map[string]string
- func OAMAppTrigger() handler.EventHandler
- func RandStringRunes(n int) string
- func Run(ctx context.Context, options *Options) error
- func Setup(ctx context.Context, mgr ctrl.Manager, options *Options) error
- func ToRawExtension(obj any) *runtime.RawExtension
- type ModelServe
- type OAMWebServiceProperties
- type OAMWebServicePropertiesEnv
- type OAMWebServicePropertiesPort
- type OAMWebServicePropertiesVolumeMount
- type OAMWebServicePropertiesVolumeMountItem
- type OAMWebServicePropertiesVolumeMounts
- type Options
- type Reconciler
- type SeldonModelServe
Constants ¶
View Source
const ( ControllerConcurrency = 5 DefaultSubdomainLen = 8 )
View Source
const ModelContainerName = "model"
View Source
const ModelInitializerVolumeSuffix = "provision-location"
View Source
const SeldonModelServeKind = "seldon"
Variables ¶
This section is empty.
Functions ¶
func ApplyObject ¶
func CreateOrUpdateContainer ¶
func OAMAppTrigger ¶
func OAMAppTrigger() handler.EventHandler
func RandStringRunes ¶
RandStringRunes generates a random string of letters and digits (lowercase)
func ToRawExtension ¶
func ToRawExtension(obj any) *runtime.RawExtension
Types ¶
type ModelServe ¶
type ModelServe interface { Watches() client.Object Apply(ctx context.Context, md *modelsv1beta1.ModelDeployment) error }
type OAMWebServiceProperties ¶
type OAMWebServiceProperties struct { Labels map[string]string `json:"labels,omitempty"` Annotations map[string]string `json:"annotations,omitempty"` Image string `json:"image,omitempty"` ImagePullPolicy string `json:"imagePullPolicy,omitempty"` Ports []OAMWebServicePropertiesPort `json:"ports,omitempty"` ExposeType string `json:"exposeType,omitempty"` CMD []string `json:"cmd,omitempty"` ENV []OAMWebServicePropertiesEnv `json:"env,omitempty"` CPU string `json:"cpu,omitempty"` Memory string `json:"memory,omitempty"` VolumeMounts OAMWebServicePropertiesVolumeMounts `json:"volumeMounts,omitempty"` }
type OAMWebServicePropertiesEnv ¶
type OAMWebServicePropertiesEnv struct { Name string `json:"name"` Value string `json:"value"` ValueFrom *corev1.EnvVarSource `json:"valueFrom,omitempty"` }
type OAMWebServicePropertiesVolumeMount ¶
type OAMWebServicePropertiesVolumeMount struct { Name string `json:"name,omitempty"` MountPath string `json:"mountPath,omitempty"` ClaimName string `json:"claimName,omitempty"` CMName string `json:"cmName,omitempty"` SecretName string `json:"secretName,omitempty"` Medium string `json:"medium,omitempty"` // when EmptyDir Path string `json:"path,omitempty"` // when HostPath DefaultMode int `json:"defaultMode,omitempty"` Items []OAMWebServicePropertiesVolumeMountItem `json:"items,omitempty"` }
type OAMWebServicePropertiesVolumeMounts ¶
type OAMWebServicePropertiesVolumeMounts struct { PVC []OAMWebServicePropertiesVolumeMount `json:"pvc,omitempty"` ConfigMap []OAMWebServicePropertiesVolumeMount `json:"configMap,omitempty"` Secret []OAMWebServicePropertiesVolumeMount `json:"secret,omitempty"` EmptyDir []OAMWebServicePropertiesVolumeMount `json:"emptyDir,omitempty"` HostPath []OAMWebServicePropertiesVolumeMount `json:"hostPath,omitempty"` }
type Options ¶
type Options struct { MetricsAddr string `json:"metricsAddr,omitempty" description:"The address the metric endpoint binds to."` EnableLeaderElection bool `json:"enableLeaderElection,omitempty" description:"Enable leader election for controller manager."` ProbeAddr string `json:"probeAddr,omitempty" description:"The address the probe endpoint binds to."` IngressHost string `json:"ingressHost,omitempty" description:"The base host of the ingress."` IngressScheme string `json:"ingressScheme,omitempty" description:"The scheme of the ingress."` }
func DefaultOptions ¶
func DefaultOptions() *Options
type Reconciler ¶
type Reconciler struct { client.Client Options *Options SeldonBack *SeldonModelServe }
func (*Reconciler) Default ¶
func (r *Reconciler) Default(ctx context.Context, md *modelsv1beta1.ModelDeployment) error
func (*Reconciler) Sync ¶
func (r *Reconciler) Sync(ctx context.Context, md *modelsv1beta1.ModelDeployment) error
type SeldonModelServe ¶
func (*SeldonModelServe) Apply ¶
func (r *SeldonModelServe) Apply(ctx context.Context, md *modelsv1beta1.ModelDeployment) error
func (*SeldonModelServe) Watches ¶
func (r *SeldonModelServe) Watches() client.Object
Click to show internal directories.
Click to hide internal directories.