Solo Enterprise for kagent
Deploy an agent to a Kubernetes cluster with Solo Enterprise for kagent.
Before you begin
- Follow the Solo Enterprise for kagent quickstart to set up Solo Enterprise for agentregistry and connect Solo Enterprise for kagent as a runtime.
- Create an agent.
- Build the Docker container image and push it to a container registry that your cluster can pull from.
- Publish the agent.
- Port-forward the Solo Enterprise for agentregistry service on your local machine.
kubectl -n agentregistry-system port-forward svc/agentregistry-enterprise-server 12121:12121
Deploy the agent
List the runtimes that are connected to Solo Enterprise for agentregistry and note the name of the runtime that you want to deploy your agent to. In the following example, the runtime name is
kagent.arctl get runtimesExample output:
NAME TYPE kagent KagentSave your Gemini API key as an environment variable. To retrieve your API key, log in to the Google AI Studio and select API Keys. This key is required to interact with the agent through the Gemini LLM provider later.
export GOOGLE_API_KEY=<apikey>Create a Deployment for the agent. The registry spins up a Kubernetes pod for your agent from the Docker image reference that is stored in the registry catalog. The
envsetting passes the Gemini API key through to the agent container so it can call the Gemini API after it is deployed.arctl apply -f - <<EOF apiVersion: ar.dev/v1alpha1 kind: Deployment metadata: name: myagent # must match agent's metadata.name spec: targetRef: kind: Agent name: myagent tag: "latest" runtimeRef: kind: Runtime name: kagent env: GOOGLE_API_KEY: "$GOOGLE_API_KEY" EOFSetting Description targetRefThe AI artifact that you want to deploy. In this example, you deploy the myagentagent that is published in the registry catalog.runtimeRefThe name of the runtime that you want to deploy to. envPass the Gemini API key through to the agent container as an environment variable so it can call the Gemini API after it is deployed. Example output:
✓ Deployment/myagent createdOpen the Instances view in the UI and select the agent that you deployed. You can monitor the progress of the deployment in the Instance Logs section. Note that the deployment can take a few minutes to complete.
Check the agent deployment in your cluster and make sure that the pod is up and running.
kubectl get pods -n kagent | grep myagentExample output:
myagent-85bf9949c9-gp49h 1/1 Running 0 5m35s
Chat with the agent
You can chat with the agent by using the Solo Enterprise for agentregistry UI.
Open the Instances view in the UI and select the
myagentagent.In the Agent Details card, click Open Chat.
Chat with the agent. For example, you can ask it what it can do for you. Then, hit Enter and wait for the agent to reply.