Create a KrakenD Agent Gateway

This guide walks you through deploying a KrakenD instance using the AgentGateway custom resource.

Before following this guide, make sure you have the KrakenD Agent Gateway Operator installed. See Install the AI Gateway KrakenD Operator for installation instructions.

Create an AgentGateway Resource

  1. Create a AgentGateway resource file:

    apiVersion: runtime.agentic-layer.ai/v1alpha1
    kind: AgentGateway
    metadata:
      name: agent-gateway
      namespace: agent-gateway
    spec:
      replicas: 1
      timeout: 5m0s
  2. Apply the configuration:

    kubectl apply -f my-agentgateway.yaml

Verify the Deployment

  1. Check the AgentGateway status:

    kubectl get agentgateways agent-gateway -n agent-gateway
  2. Verify the created resources:

    # Check the deployment created by the operator
    kubectl get deployments -l app=agent-gateway -A
    
    # Check the service
    kubectl get services -l app=agent-gateway -A
    
    # Check the configmap with KrakenD configuration
    kubectl get configmaps agent-gateway-krakend-config -n agent-gateway
  3. Check the pod logs to ensure KrakenD started successfully:

    kubectl logs -l app=agent-gateway -n agent-gateway