Model inference on Kubernetes with KServe

KServe gives Kubernetes teams a standard way to serve predictive and generative models on GPU nodes they control. This page covers what it does, when to choose it, and what the work involves.

On this page

When KServe is the model inference layer for Kubernetes

KServe is a model inference layer that a platform team runs on Kubernetes so other teams can call models through stable, versioned endpoints. It fits when the platform team operates the clusters, several teams need to deploy or call models, and the organization needs to keep model weights and inference traffic inside infrastructure it controls. A team that serves one model for one application may find a simpler deployment easier to run, so the decision should follow the number of models, the number of consuming teams and the operating skills available in the platform group.

The central object is the InferenceService, a Kubernetes custom resource in which the platform team declares where a model's artifacts are stored, which runtime serves it, what accelerator and memory it requests, and how the endpoint scales. A serving runtime is the reusable definition of the container and the model formats it can load, so application teams choose a model and the platform team controls the images behind it. Generative models are usually served by a runtime built on an inference engine. The topic context names vLLM and llm-d as backends for this. Confirm the runtime resource names, the custom resource API version, the supported model formats and the OpenAI-compatible endpoint behavior in the KServe documentation for the release you plan to run, because these details change between releases.

Before you commit, make three decisions. List the runtimes you will allow and the images each one pulls, since those images will need to come from your private registry in a cluster without internet access. Decide which group owns the serving runtime objects and who may create an InferenceService in each namespace. Then check the Kubernetes version against the version skew policy, because the control plane must be upgraded before nodes and the KServe release you pick must support your target Kubernetes minor version. Write these answers into the design before any GPU node is labeled, so the cluster is shaped around the serving model rather than retrofitted to it.

What KServe puts on your cluster

A KServe installation adds a small set of custom resources, controllers and runtime images to your Kubernetes cluster. Each piece has its own version, configuration and failure modes, so the team should review them together before any model goes live. The exact resources, supported versions and runtime options must be confirmed against the KServe release you plan to deploy.

The InferenceService resource

An InferenceService is the custom resource that declares one served model: where its artifacts live, which runtime loads it, the GPU and memory requests, and the replica bounds. Platform teams usually treat it as the contract between data scientists and the cluster. Check which API version your release serves, how predictors and transformers are declared, and whether your admission policies accept the fields your teams will write.

KServe docs

Serving runtimes and vLLM

A serving runtime is the template that tells KServe which container image loads a model and how it listens for requests. For large language models, vLLM is one runtime option that exposes an OpenAI-compatible API. Confirm which runtimes ship with your release, which image versions they pin, and whether each one supports the model formats and GPU types you have. Custom runtimes add images you must build, scan and maintain.

The llm-d backend

llm-d is a distributed inference backend that can sit behind KServe for generative workloads that need more than one replica to serve traffic efficiently. Its value depends on how your cluster handles scheduling, cache-aware routing and multi-node placement. Before adopting it, confirm which KServe release supports it, which GPU and networking features it requires, and how it is upgraded alongside the runtimes it depends on.

Ingress and gateway path

Requests reach a model through an ingress or Gateway API layer that KServe configures for each service. This path decides the hostnames, TLS termination, authentication hooks and how traffic splits between model revisions. Confirm which gateway implementation your release targets, who owns the certificates, and how the gateway integrates with your identity provider and network policies. Misaligned ownership here is a common source of outages during upgrades.

Autoscaling behavior

KServe can scale model replicas with demand, including scale to zero in some configurations. Scaling a GPU-backed model is slow, because new pods must pull large images, load weights and wait for accelerator capacity. Confirm which autoscaler your release uses, which metrics drive scaling, and how cold starts affect latency targets. Pair the settings with cluster autoscaling and GPU quota so that scaling requests do not stall.

Canary rollout mechanism

KServe can send a percentage of traffic to a new model revision while the previous revision keeps serving the rest. This lets teams compare quality and latency before a full cutover. Confirm how traffic percentages are set, how rollbacks are triggered, and whether your monitoring can separate metrics per revision. Agree in advance who approves promotion, because the rollout mechanism moves traffic but does not judge model quality.

How a model request flows through KServe on GPU nodes

A client request enters through a gateway or ingress that sits on the edge of the cluster, which is where the trust boundary is drawn. KServe routes the request to the InferenceService, where a canary split can send a share of traffic to a new revision while the current one keeps serving. The model server pod runs on a GPU node and loads weights from model storage or a local cache. Check the boundary controls at the gateway, who may update the traffic split, and whether the cache holds only approved model artifacts. This is a generic illustration, and your own gateway, backend and storage choices will change the exact components.

Generic illustration of a KServe request path, with the cluster trust boundary shown as a subgraph.

Choosing a serving backend and rollout pattern

This table compares the backend, scaling and rollout options a team must settle before deploying models with KServe. Read each row as a decision: when the option fits, what it costs you, and what to confirm with the project or vendor before committing.

OptionWhen it fitsMain trade-offWhat to confirm
vLLM as the generative engineSingle-model LLM serving where one GPU or a small set of GPUs holds the model and you need an OpenAI-compatible APIYou own GPU sizing, model caching and tuning of batch and memory settings per modelSupported model architectures, GPU types and the vLLM version your KServe release tests against
llm-d for distributed servingLarge models or high request volume that need multi-replica routing and cache-aware scheduling across GPUsMore moving parts to operate, and a newer stack with a smaller body of production referencesCurrent project maturity, supported gateways, and which KServe releases integrate with it
Predictive runtimes for classic modelsTabular, scikit-learn, XGBoost or similar models that do not need token streaming or GPU-heavy batchingLess suited to generative workloads, so LLM traffic may need a separate serving pathWhich runtime images your KServe version ships and how each handles your model format
Raw deployment modeSteady traffic, predictable GPU capacity, or workloads that need full control of Kubernetes Deployments and autoscalingYou manage replica counts, autoscaling rules and idle GPU cost yourselfHow your chosen autoscaler is configured and which metrics signal load for your model
Serverless-style scalingSpiky traffic where scaling to zero or fast scale-out matters more than cold-start latencyCold starts can be long for large model weights, and it adds a dependency on the Knative stackWhether your Knative and networking setup is supported with your KServe release and GPU nodes
Canary rolloutNew model or runtime versions where you need to shift a share of traffic and compare quality or latency firstTwo versions run at once, which doubles GPU use during the rollout windowHow traffic split is configured, which metrics gate promotion and how rollback is triggered
Full rolloutLow-risk changes such as a patch to the same model artifact, or when a canary has already been validated elsewhereFaster, but a bad model or runtime reaches all users at onceWhether your rollback path, previous revision retention and health checks are tested before cutover

Model storage, caching and cold starts on GPU nodes

Model startup time is usually decided by how the weights reach the GPU node, not by the serving engine. A large language model's weight files can run to many gigabytes, and every new replica, node replacement or rolling update repeats the pull unless the weights are already on local disk. For a KServe InferenceService backed by vLLM or llm-d, the plan should name where the weights live at rest (object storage, a persistent volume or a pre-staged node cache), who copies them onto the node, and how long a pod waits before it can pass its readiness probe. Measure these in your own environment: the time from pod scheduling to a loaded model, the download throughput from your storage backend to a GPU node, and how many replicas a single rollout starts at once.

Each storage pattern trades startup speed against operating effort. Pulling from object storage at pod start is simple and keeps one source of truth, but it makes every cold start depend on network and storage capacity during scale-out. A PersistentVolumeClaim with a ReadWriteMany mode lets replicas share one copy, but only if your storage class supports that access mode and read throughput holds under concurrent readers. Pre-staging weights onto node-local disk is the fastest path to a warm start, and it needs a controlled job or DaemonSet to refresh copies when a model version changes. Confirm with your storage vendor which access modes and throughput limits apply, and test a scale-out from zero before you commit to a pattern.

Air-gapped clusters need two mirrors before the first model can be served: a private container registry for the serving images and a model mirror holding the exact weight files, tokenizer files and configuration each approved version requires. Decide who approves an import into the mirror, record checksums for each artifact, and make the InferenceService reference the mirrored location rather than a public hub. Image references must also point at the private registry, which is the same approach kubeadm uses through --image-repository for control plane images. Plan the mirror refresh cadence, retention of superseded versions for rollback, and the disk headroom on GPU nodes, because a pre-staged cache that fills a node's root disk causes evictions that look like model failures.

How to set up KServe for a GPU inference platform

This sequence takes a self-managed Kubernetes cluster from bare GPU nodes to a served, OpenAI-compatible model endpoint with gateway access, identity, autoscaling and a canary path. Each step ends with a check you can run before moving on.

  1. Prepare GPU nodes and the device plugin

    The platform team labels GPU nodes, confirms the driver and container runtime stack on each node, and makes the GPU resource visible to the scheduler through the device plugin. Whether drivers come from a preinstalled image or a driver container is a decision to settle here, because it affects how later driver upgrades are scheduled. Done means a test pod that requests one GPU starts, runs nvidia-smi, and exits, and the node reports allocatable GPU capacity. Confirm the exact operator and plugin versions with your GPU vendor's support matrix before you pin them.

  2. Install KServe and its dependencies

    Install the KServe controller and its serving runtimes into a dedicated namespace, along with the dependencies it needs for ingress and autoscaling in your chosen mode. Confirm which serverless or raw deployment mode fits your traffic pattern and which components your cluster already runs, such as a networking layer and a metrics stack. Done means the KServe controller pods are ready, the custom resource definitions are registered, and the cluster-level serving runtimes list the backends you plan to use, including vLLM. Check the KServe release notes against your Kubernetes minor version before installing.

  3. Configure the gateway and identity

    Set up the ingress path that will receive client traffic, define the hostname and TLS certificates, and connect authentication so that only approved callers reach model endpoints. Decide where tokens are issued, which OIDC client each application uses, and how service accounts for batch callers are handled. Done means an unauthenticated request to the inference route is rejected, and an authenticated request from an approved client reaches the KServe service. Record the issuer and audience values so later rotations do not break callers.

  4. Stage model artifacts in a private store

    Copy model weights, tokenizer files and configuration into storage your cluster can reach without internet access, such as an internal object store or a private registry for model images. Verify checksums, record the model version and license terms, and decide whether nodes cache weights locally to shorten cold starts. The cluster also needs the container images for the serving runtime mirrored into the private registry. Done means a pod can load the model from the internal location in a test run, and the artifact versions match your record.

  5. Deploy a first InferenceService

    Create an InferenceService that points at the staged model, requests GPUs, sets resource limits and readiness and liveness probes, and selects the vLLM runtime for an OpenAI-compatible API. Keep the first deployment small in replicas so failures are easy to trace. Done means the predictor pod reports ready only after the model finishes loading, a request to the chat or completions path returns a valid response, and the pod's GPU allocation matches what the spec requests. Use the vLLM deployment guidance to confirm model compatibility before scaling.

  6. Configure autoscaling and a canary rollout

    Set minimum and maximum replicas, choose the scaling signal (concurrency, request rate or a custom metric such as queue depth), and tune scale-down so warm GPU pods are not removed mid-request. Then configure a canary by sending a small share of traffic to a new model revision and keeping the previous revision as the stable target. Done means a load test scales the predictor up and back down as expected, and a canary split routes the stated percentage of requests to the new revision. Record the rollback command before the first real canary.

  7. Verify health, GPU allocation and recovery

    Run a checklist at each earlier step and again after scaling: probe results, GPU allocation per pod, no GPU shared unintentionally across workloads, metrics and logs flowing to your monitoring stack, and a restart of a predictor pod that returns cleanly to ready. Test a node drain on a GPU node to confirm the endpoint recovers within the behavior your service needs. Done means every check is recorded in a runbook, with the owner and the command used, so the next upgrade can repeat it.

Security and operational risks to design for

Model serving puts GPU hardware, model artifacts, credentials and user prompts behind one endpoint, so a weakness in any layer exposes the others. The cards below cover the risks that most often surface in reviews of self-managed KServe clusters. Check each one before the first production model goes live, and again when KServe, Kubernetes or GPU drivers change.

Unauthenticated inference endpoints

An InferenceService that is reachable without authentication lets any internal caller run GPU workloads, scrape model outputs or drive up cost. Decide where authentication happens, at the gateway, in the serving layer or both, and confirm that every route, including health and metrics paths, is covered. Test the endpoint from a namespace that should have no access. Treat every unauthenticated path as an exposure until a test proves otherwise.

Kubernetes authentication

Model and credential handling

Model artifacts often sit in buckets or registries that need pull credentials, and runtimes may need tokens for private model hubs. Kubernetes Secrets are stored unencrypted in etcd by default, so confirm encryption at rest is enabled and that list and watch access on Secrets is restricted with least-privilege RBAC. Consider an external secret store through the Secrets Store CSI Driver for rotation. Ask who can read the storage credentials that point to model weights.

Secrets good practices

GPU node isolation for multiple teams

When several teams share GPU nodes, a pod that runs privileged or mounts host paths can reach other teams' model data and devices. Enforce Pod Security Standards per namespace, starting with Restricted where model runtimes allow it, and document any namespace that needs a looser level and why. Keep serving namespaces separate from training and experimentation workloads. Confirm the GPU device plugin and runtime settings do not widen access beyond the intended pods.

Pod Security Standards

Least-privilege RBAC for InferenceService changes

Changing an InferenceService can alter the model version, the storage source, the scaling limits and the traffic split, so it is a production change. Limit create, update and patch rights to the team that owns each model, and keep rights to modify serving runtimes separate from rights to deploy models. Review service account permissions for the controller and for CI pipelines that apply manifests. Ask who can route traffic to a canary.

Secrets good practices

Audit logging of access and prompts

Kubernetes audit logs record API activity such as who changed an InferenceService, but they do not record the content of prompts or responses. If prompts or outputs are sensitive, decide whether the gateway or the serving layer logs them, how long they are kept and who can read them. Logging full prompts can create a new data store with its own exposure. Confirm the retention period and access controls with your compliance team before enabling it.

Upgrade coordination across the stack

KServe, the serving runtimes, Kubernetes, the GPU driver and the container toolkit each have their own compatibility limits, so a single upgrade can break inference across the cluster. Follow the Kubernetes version skew policy for control plane and kubelet order, and test each KServe and runtime release against the target Kubernetes version and driver before rollout. Plan canary rollouts for model and runtime changes, and keep the previous serving images available for rollback.

Questions teams ask before running KServe in-house

What drives the cost and effort of an in-house KServe build?

The main drivers are the number of models, the GPU capacity they need, and how many serving runtimes your team must operate. Cost splits into one-time work (cluster preparation, runtime selection, authentication, autoscaling and canary design, testing) and recurring work (model updates, runtime upgrades, GPU driver maintenance, monitoring and on-call). Staff time is usually the largest line item, and GPU hardware or cloud capacity is often the largest recurring one. Ask any quote to separate these components, state which GPU capacity is assumed, and list what is excluded, such as hardware, licenses or model development. Hardware and per-hour GPU rates come from your own infrastructure or provider, not from the implementation scope.

How long does a KServe setup take, and what makes it longer?

Duration depends less on KServe itself and more on the prerequisites around it. Teams usually lose time on GPU node preparation, storage for model weights, identity and gateway integration, and agreeing on which serving runtime each model type uses. Multi-tenant clusters, air-gapped registries and strict change control add steps. A fixed-scope plan should list the number of models, environments and integrations, then give a timeline per phase. Treat any single duration without a stated scope as a guess and ask the partner to show the assumptions behind it.

What does the work need from our own team?

Expect to provide cluster access, a named owner for the GPU nodes, a model registry or object store with approved artifacts, identity provider details, and sign-off from security and the teams that will call the endpoints. Engineers who will operate the platform should join the build so they can run upgrades and troubleshoot after handover. Your team also decides service-level expectations, model approval rules and who may deploy a new model version. Agree these responsibilities in writing before the build starts so that gaps appear during planning, not during rollout.

Can a platform team run KServe without outside help?

A platform team with Kubernetes operations experience and some GPU background can usually build a working setup on its own, given time for learning and testing. The harder part is operating it under load: GPU scheduling, autoscaling behavior on inference traffic, model caching, and safe canary rollouts all need tuning against real workloads. Ask whether the team has someone who has run GPU workloads in production and whether there is capacity for on-call duty. An external partner can shorten the learning curve, but internal ownership still has to exist for the platform to last.

How does KServe fit with Kubernetes upgrades?

KServe runs on Kubernetes, so each Kubernetes minor version upgrade must be checked against the KServe release, its serving runtimes and the GPU operator. Kubernetes publishes a version skew policy that requires the kube-apiserver to be upgraded one minor version at a time, before the controller manager, scheduler and kubelets, and allows kubelets to be up to three minor versions older than the API server. Plan a test cluster for each upgrade, and confirm which Kubernetes versions your chosen KServe release supports before you move production. Inference nodes should be drained with model replicas kept available where possible.

What should we ask for in a fixed-scope quote?

Ask for a written scope that lists the models and serving runtimes in scope, the cluster and GPU nodes involved, the integrations (identity, gateway, monitoring, storage), the environments, and the acceptance tests. Request deliverables such as architecture notes, runbooks, configuration in version control and a handover session. Check which items are one-time and which need an ongoing retainer, such as upgrades and continuous testing. Ask what is excluded, including GPU hardware, model fine-tuning, and third-party licenses, and how changes to scope are priced and approved.

Who owns security for the inference endpoints?

Your organization owns the decisions, and the implementation should make them enforceable. Endpoints need authentication, access policy per model, network controls, and audit logging of requests and administrative changes. Kubernetes authenticates users through certificates, tokens including OpenID Connect, webhooks or an authenticating proxy, so the identity design should be agreed early. Secrets for model storage and registries should not sit unencrypted in etcd by default, so confirm encryption at rest and least-privilege access. DeployOpen can test the deployed endpoints as part of a separate security testing engagement.

Limits to confirm in your environment

KServe, the serving runtimes behind it and the GPU stack underneath all publish their own compatibility limits, and those limits change between releases. The cards below cover the checks that most often decide whether a serving design works on your cluster. Confirm each one against the project documentation and then prove it on a test cluster that matches your production nodes.

Kubernetes version support

Every KServe release targets a range of Kubernetes minor versions, and that range sets which cluster you can run it on. Check the compatibility table in the KServe release you plan to install against the minor version your cluster runs or will run after its planned upgrades. Also check the Kubernetes release you are on: only the three most recent minor releases receive upstream support, so a serving stack pinned to an older cluster version can end up on an unsupported base. Record the chosen pairing in your architecture document.

Kubernetes releases

GPU driver and runtime compatibility

The serving runtime, the CUDA libraries it ships with, the NVIDIA driver on each node and the device plugin must agree. A runtime image built for one CUDA major version may fail on nodes running a driver that is too old for it. Confirm the minimum driver version for the runtime image you select, the GPU models and compute capability it supports, and whether your node pool uses preinstalled drivers or driver containers. Test a rolling driver upgrade on a single node pool before you schedule production models onto it.

Model architecture support

A runtime that loads a model format does not guarantee that it supports every architecture in that format. Mixture-of-experts layers, multimodal inputs, quantized weights and long context windows each depend on specific runtime versions and sometimes specific flags. For each model you plan to serve, confirm the architecture, quantization method and precision are listed as supported in the runtime release you will deploy. Load the exact weights on a test node and run a fixed set of prompts, because a model that starts is not proof that it returns correct output.

Gateway and autoscaling feature support

Serving features such as scale to zero, request-based autoscaling, canary traffic splitting and the choice of ingress or Gateway API layer depend on the networking and metrics components installed in your cluster. Confirm which autoscaler KServe uses in your deployment mode, which metrics it reads (for example, request concurrency or GPU utilization), and whether your gateway implementation supports the traffic-splitting behavior you need. Scale-to-zero on GPU nodes also needs a cold-start budget that your users will accept.

Vendor constraints and workload fit

Each runtime and the KServe project state constraints on request size, batch behavior, supported tensor parallelism and maximum model size per pod. A workload that breaks those constraints will fail under load even when the smoke test passes. Read the stated limits for your runtime, compare them with your expected prompt lengths, concurrency and model size, and confirm the result with a load test at your target traffic. Ask the runtime maintainers or your support contract holder about any limit the documentation leaves unclear.

Your own test cluster

Project documentation describes the tested configurations, and your cluster will differ in node hardware, network policy, storage class, admission rules and registry access. Build a test cluster that mirrors the production GPU nodes, storage and gateway, then run install, upgrade, rollback and load tests there. Record the versions of KServe, Kubernetes, the GPU stack and the runtime in use, so that a later upgrade can be repeated exactly. Treat any gap between the documentation and your test results as a blocker until it is explained.

How DeployOpen scopes and delivers KServe platforms

DeployOpen plans, implements, hardens and documents self-hosted open-source platforms inside the client's own infrastructure, and a KServe platform is delivered the same way. The work runs in your cloud accounts, data centers or air-gapped network, so the GPU nodes, model artifacts, inference traffic and logs stay under your control from the first design session. Before any build starts, the scope should settle which parts of the stack are in play: the KServe controller and its serving runtimes, the chosen backends such as vLLM or llm-d, the GPU Operator and node pools, the ingress or gateway path, model storage, and the identity and audit controls your security team will review.

Most engagements are fixed-scope, with the scope, deliverables and timelines agreed in writing before work starts. For a KServe platform, a written scope should name the model types and sizes to be served, the endpoints clients will call, the autoscaling and canary rollout behavior expected, the hardening baseline (for example, the Pod Security Standards level applied to the serving namespaces), the backup and recovery expectations for model registries and configuration, and the handover documentation. Ask for the deliverables list and the acceptance criteria in the same document, and confirm which items depend on work your own teams or other vendors own, such as GPU driver lifecycle or network approvals. Any timeline should be tied to those dependencies rather than to a generic estimate.

Platforms that serve models rarely stay static, so DeployOpen also offers ongoing support, upgrades and continuous testing as retainers. For KServe this typically covers tracking Kubernetes minor version upgrades, KServe and backend releases, model image updates, and periodic review of access and configuration settings. When you evaluate a retainer, ask what is included per upgrade cycle, how security fixes are handled between cycles, who on your side approves changes to production serving, and how the retainer is priced against the scope. DeployOpen does not publish a price list, so a quote follows from the written scope and the retainer terms.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.