Skip to content

Latest commit

 

History

History
301 lines (214 loc) · 15.3 KB

File metadata and controls

301 lines (214 loc) · 15.3 KB

API Reference

Packages

llamastack.io/v1alpha1

Package v1alpha1 contains API Schema definitions for the v1alpha1 API group

Resource Types

AllowedFromSpec

AllowedFromSpec defines namespace-based access controls for NetworkPolicies.

Appears in:

Field Description Default Validation
namespaces string array Namespaces is an explicit list of namespace names allowed to access the service.
Use "*" to allow all namespaces.
labels string array Labels is a list of namespace label keys that are allowed to access the service.
A namespace matching any of these labels will be granted access (OR semantics).
Example: ["myproject/lls-allowed", "team/authorized"]

AutoscalingSpec

AutoscalingSpec configures HorizontalPodAutoscaler targets.

Appears in:

Field Description Default Validation
minReplicas integer MinReplicas is the lower bound replica count maintained by the HPA
maxReplicas integer MaxReplicas is the upper bound replica count maintained by the HPA
targetCPUUtilizationPercentage integer TargetCPUUtilizationPercentage configures CPU based scaling
targetMemoryUtilizationPercentage integer TargetMemoryUtilizationPercentage configures memory based scaling

CABundleConfig

CABundleConfig defines the CA bundle configuration for custom certificates

Appears in:

Field Description Default Validation
configMapName string ConfigMapName is the name of the ConfigMap containing CA bundle certificates
configMapNamespace string ConfigMapNamespace is the namespace of the ConfigMap (defaults to the same namespace as the CR)
configMapKeys string array ConfigMapKeys specifies multiple keys within the ConfigMap containing CA bundle data
All certificates from these keys will be concatenated into a single CA bundle file
If not specified, defaults to [DefaultCABundleKey]
MaxItems: 50

ContainerSpec

ContainerSpec defines the llama-stack server container configuration.

Appears in:

Field Description Default Validation
name string llama-stack
port integer
resources ResourceRequirements
env EnvVar array
command string array
args string array

DistributionConfig

DistributionConfig represents the configuration information from the providers endpoint.

Appears in:

Field Description Default Validation
activeDistribution string ActiveDistribution shows which distribution is currently being used
providers ProviderInfo array
availableDistributions object (keys:string, values:string) AvailableDistributions lists all available distributions and their images

DistributionPhase

Underlying type: string

LlamaStackDistributionPhase represents the current phase of the LlamaStackDistribution

Validation:

  • Enum: [Pending Initializing Ready Failed Terminating]

Appears in:

Field Description
Pending LlamaStackDistributionPhasePending indicates that the distribution is pending initialization
Initializing LlamaStackDistributionPhaseInitializing indicates that the distribution is being initialized
Ready LlamaStackDistributionPhaseReady indicates that the distribution is ready to use
Failed LlamaStackDistributionPhaseFailed indicates that the distribution has failed
Terminating LlamaStackDistributionPhaseTerminating indicates that the distribution is being terminated

DistributionType

DistributionType defines the distribution configuration for llama-stack.

Appears in:

Field Description Default Validation
name string Name is the distribution name that maps to supported distributions.
image string Image is the direct container image reference to use

LlamaStackDistribution

Appears in:

Field Description Default Validation
apiVersion string llamastack.io/v1alpha1
kind string LlamaStackDistribution
kind string Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
apiVersion string APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec LlamaStackDistributionSpec
status LlamaStackDistributionStatus

LlamaStackDistributionList

LlamaStackDistributionList contains a list of LlamaStackDistribution.

Field Description Default Validation
apiVersion string llamastack.io/v1alpha1
kind string LlamaStackDistributionList
kind string Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
apiVersion string APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
metadata ListMeta Refer to Kubernetes API documentation for fields of metadata.
items LlamaStackDistribution array

LlamaStackDistributionSpec

LlamaStackDistributionSpec defines the desired state of LlamaStackDistribution.

Appears in:

Field Description Default Validation
replicas integer 1
server ServerSpec
network NetworkSpec Network defines network access controls for the LlamaStack service

LlamaStackDistributionStatus

LlamaStackDistributionStatus defines the observed state of LlamaStackDistribution.

Appears in:

Field Description Default Validation
phase DistributionPhase Phase represents the current phase of the distribution Enum: [Pending Initializing Ready Failed Terminating]
version VersionInfo Version contains version information for both operator and deployment
distributionConfig DistributionConfig DistributionConfig contains the configuration information from the providers endpoint
conditions Condition array Conditions represent the latest available observations of the distribution's current state
availableReplicas integer AvailableReplicas is the number of available replicas
serviceURL string ServiceURL is the internal Kubernetes service URL where the distribution is exposed
routeURL string RouteURL is the external URL where the distribution is exposed (when exposeRoute is true).
nil when external access is not configured, empty string when Ingress exists but URL not ready.

NetworkSpec

NetworkSpec defines network access controls for the LlamaStack service.

Appears in:

Field Description Default Validation
exposeRoute boolean ExposeRoute when true, creates an Ingress for external access.
Default is false (internal access only).
false
allowedFrom AllowedFromSpec AllowedFrom defines which namespaces are allowed to access the LlamaStack service.
By default, only the LLSD namespace and the operator namespace are allowed.

PodDisruptionBudgetSpec

PodDisruptionBudgetSpec defines voluntary disruption controls.

Appears in:

Field Description Default Validation
minAvailable IntOrString MinAvailable is the minimum number of pods that must remain available
maxUnavailable IntOrString MaxUnavailable is the maximum number of pods that can be disrupted simultaneously

PodOverrides

PodOverrides allows advanced pod-level customization.

Appears in:

Field Description Default Validation
serviceAccountName string ServiceAccountName allows users to specify their own ServiceAccount
If not specified, the operator will use the default ServiceAccount
terminationGracePeriodSeconds integer TerminationGracePeriodSeconds is the time allowed for graceful pod shutdown.
If not specified, Kubernetes defaults to 30 seconds.
volumes Volume array
volumeMounts VolumeMount array

ProviderHealthStatus

HealthStatus represents the health status of a provider

Appears in:

Field Description Default Validation
status string
message string

ProviderInfo

ProviderInfo represents a single provider from the providers endpoint.

Appears in:

Field Description Default Validation
api string
provider_id string
provider_type string
config JSON
health ProviderHealthStatus

ServerSpec

ServerSpec defines the desired state of llama server.

Appears in:

Field Description Default Validation
distribution DistributionType
containerSpec ContainerSpec
workers integer Workers configures the number of uvicorn worker processes to run.
When set, the operator will launch llama-stack using uvicorn with the specified worker count.
Ref: https://fastapi.tiangolo.com/deployment/server-workers/
CPU requests are set to the number of workers when set, otherwise 1 full core
Minimum: 1
podOverrides PodOverrides
podDisruptionBudget PodDisruptionBudgetSpec PodDisruptionBudget controls voluntary disruption tolerance for the server pods
topologySpreadConstraints TopologySpreadConstraint array TopologySpreadConstraints defines fine-grained spreading rules
autoscaling AutoscalingSpec Autoscaling configures HorizontalPodAutoscaler for the server pods
storage StorageSpec Storage defines the persistent storage configuration
userConfig UserConfigSpec UserConfig defines the user configuration for the llama-stack server
tlsConfig TLSConfig TLSConfig defines the TLS configuration for the llama-stack server

StorageSpec

StorageSpec defines the persistent storage configuration

Appears in:

Field Description Default Validation
size Quantity Size is the size of the persistent volume claim created for holding persistent data of the llama-stack server
mountPath string MountPath is the path where the storage will be mounted in the container

TLSConfig

TLSConfig defines the TLS configuration for the llama-stack server

Appears in:

Field Description Default Validation
caBundle CABundleConfig CABundle defines the CA bundle configuration for custom certificates

UserConfigSpec

Appears in:

Field Description Default Validation
configMapName string ConfigMapName is the name of the ConfigMap containing user configuration
configMapNamespace string ConfigMapNamespace is the namespace of the ConfigMap (defaults to the same namespace as the CR)

VersionInfo

VersionInfo contains version-related information

Appears in:

Field Description Default Validation
operatorVersion string OperatorVersion is the version of the operator managing this distribution
llamaStackServerVersion string LlamaStackServerVersion is the version of the LlamaStack server
lastUpdated Time LastUpdated represents when the version information was last updated