Skip to main content
Version: v0.1.x

Compute Config

A Compute Config defines default settings for how PaletteAI deploys Kubernetes clusters. It captures infrastructure details, such as networking, SSH keys, and node configurations, so that data scientists and ML engineers can deploy workloads without specifying these settings each time.

Every Project must reference a Compute Config. When users deploy AI/ML applications or models, PaletteAI uses the Compute Config to provision clusters with consistent, pre-approved settings. These settings are defined in the spec.paletteClusterConfig.defaults section of the Compute Config resource.

tip

Compute Config replaces the manual configuration steps you would normally perform in Palette's cluster deployment workflow. For Edge clusters, it covers most settings entered on the Cluster Config and Nodes Config screens.

Example Compute Config configuration
apiVersion: spectrocloud.com/v1alpha1
kind: ComputeConfig
metadata:
name: edge-compute-config
namespace: project-a
spec:
paletteClusterConfig:
# Edge configuration for edge deployments
edge:
vip: '10.10.189.24'
ntpServers:
- 'time.google.com'
- 'time2.google.com'
networkOverlayConfig:
enabled: false
staticIp: true
cidr: '192.168.1.0/24'
overlayNetworkType: 'VXLAN'
isTwoNode: false
defaults:
# SSH keys for node access
sshKeys:
- 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC7... test-user@test-machine'
- 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC8... admin@admin-machine'
# Control plane pool configuration - required field
controlPlanePool:
nodeCount: 3 # Must be 1, 3, or 5 to maintain quorum
singleNodeCluster: false
architecture: 'AMD64'
cpu:
cpuCount: 8
memory:
memory: '16 GB'
workerNodeEligible: false
labels:
'palette.ai': 'true'
annotations:
'control-plane-annotation': 'control-plane-value'
'kubernetes.io/description': 'Control plane node'
taints:
- key: 'node-role.kubernetes.io/control-plane'
effect: 'NoSchedule'
# Worker pool configuration
workerPools:
- name: worker-pool-0
labels:
'palette.ai': 'true'
annotations:
'worker-annotation': 'worker-value'
'kubernetes.io/description': 'Worker node'
taints:
- key: 'worker-taint'
value: 'true'
effect: 'NoExecute'

Worker Node Eligibility

The controlPlanePool.workerNodeEligible setting determines whether control plane nodes can run workloads. When set to true, the control plane node is marked as worker-eligible, allowing it to schedule and run workloads in addition to managing the Kubernetes control plane.

For single-node clusters, the single node functions as both the control plane node and worker node. Scheduling is driven by the configured worker pool requirements, and control plane labels/taints/annotations are merged onto that pool, overriding worker pool values for overlapping fields.

Set this to true for single-node deployments and to false for multi-node deployments so that control plane nodes are dedicated to cluster management only.

info

Refer to Deploy a Single-Node Compute Pool for a step-by-step guide on configuring and deploying single-node clusters with worker-eligible control planes.

Minimum Worker Nodes

The spec.minWorkerNodes setting ensures clusters have at least a specified number of worker nodes. This is useful for workloads that require a minimum level of compute resources to function properly, such as distributed training jobs or high-availability applications.

Resolution Order

PaletteAI resolves the minimum worker node count from multiple sources in the following order:

  1. Workload Profile - The palette.ai/min-nodes: N label on the Workload Profile (highest priority)

    Example WorkloadProfile label
    apiVersion: spectrocloud.com/v1beta1
    kind: WorkloadProfile
    metadata:
    name: distributed-training
    labels:
    palette.ai/min-nodes: '3' # This workload requires at least 3 nodes
    spec:
  2. Worker Pool Config - minWorkerNodes in clusterVariant.*.nodePoolRequirements.workerPools[*] (used in either the AI Workload or ComputePool spec, depending on which path you use)

    Example AIWorkload minWorkerNodes
    apiVersion: spectrocloud.com/v1alpha1
    kind: AIWorkload
    metadata:
    name: my-workload
    spec:
    clusterVariant:
    dedicated:
    paletteClusterDeploymentConfig:
    cloudType: edge-native
    nodePoolRequirements:
    controlPlanePool:
    nodeCount: 3
    workerPools:
    - name: gpu-workers
    gpu:
    family: 'NVIDIA A100'
    gpuCount: 8
    minWorkerNodes: 3
    info

    Each worker pool requires a name field. If you do not specify a name, the system automatically generates a unique identifier for the worker pool.

If none of these sources specify a minimum worker node requirement, no minimum is enforced.

Resources

Refer to the following articles to learn more about the role Compute Config plays in PaletteAI:

  • Compute - Discovers available machines for cluster deployment
  • Compute Pool - Allocates machines and provisions clusters using Compute Config settings
  • Project - References a Compute Config for all workloads in the project