Portkey is also available on the Azure Marketplace. You can deploy Portkey directly through your Azure console, which streamlines procurement and deployment processes.Deploy via Azure Marketplace →
Components and Sizing Recommendations
Component | Options | Sizing Recommendations |
---|---|---|
AI Gateway | Deploy in your AKS cluster using Helm charts. | Use AKS B2ms worker nodes, each providing at least 2 vCPUs and 4 GiB of memory. For high availability, deploy them across multiple Availability Zones. |
Logs Store (optional) | Azure Blob Storage or S3-compatible storage | Each log document is ~10kb in size (uncompressed) |
Cache (Prompts, Configs & Providers) | Built-in Redis or Azure Cache for Redis | Deployed within the same VNet as the Portkey Gateway. |
Prerequisites
Ensure the following tools and resources are installed and available:- A running AKS cluster with at least 2 worker nodes. (Best Practice: Use 2 nodes, with one node in each Availability Zone, to ensure high availability.)
- Azure CLI
- Kubectl
- Helm (v3 or above)
Create a Portkey Account
- Go to the Portkey website.
- Sign up for a Portkey account.
- Once logged in, locate and save your
Organisation ID
for future reference. It can be found in the browser URL:https://app.portkey.ai/organisation/<organisation_id>/
- Contact the Portkey AI team and provide your Organisation ID and the email address used during signup..
- The Portkey team will share the following information with you:
- Docker credentials for the Gateway images (username and password).
- License: Client Auth Key.
Setup Project Environment
Image Credentials Configuration
Configure Components
Based on the choice of components and their configuration update thevalues.yaml
.
Cache Store
The Portkey Gateway deployment includes a Redis instance pre-installed by default. You can either use this built-in Redis or connect to an external cache likeAzure Cache for Redis
or Azure Managed Redis
.
Built-in Redis
No additional permissions or network configurations are required.Log Store
Azure Blob Storage
- (Optional) If not already done, create an Azure Storage Account and a Blob Container to store LLM logs.
-
Set up access to the log store. The Gateway supports the following methods for connecting to the Blob Storage:
- Managed Identity
- Entra ID
values.yaml
with the following configuration.- Managed Identity
- Entra ID
Network Configuration
Set up external access to the Gateway To ensure the Gateway service is accessible externally, create either an internal or internet-facing Load Balancer.Ensure Outbound Network Access
By default, Kubernetes allows full outbound access, but if your cluster has NetworkPolicies that restrict egress, configure them to allow outbound traffic. Example NetworkPolicy for Outbound Access:Deploying Portkey Gateway
Verify the deployment
To confirm that the deployment was successful, follow these steps:- Verify that all pods are running correctly.
-
Test Gateway by sending a cURL request.
- Port-forward the Gateway pod
- Once port forwarding is active, open a new terminal window or tab and send a test request by running:
- Test gateway service integration with Load Balancer.
Integrating Gateway with Control Plane
Portkey supports the following methods for integrating the Control Plane with the Data Plane/Gateway:IP Whitelisting
Allows control plane to access the Data Plane over the internet by restricting inbound traffic to specific IP address of Control Plane. This method requires the Data Plane to have a publicly accessible endpoint. To whitelist, add an inbound rule to the Azure NSG/Firewall allowing connections from the Portkey Control Plane’s IP (44.221.117.129
) on required port.
To integrate the Control Plane with the Data Plane, contact the Portkey team and provide the Public Endpoint of the Data Plane.
Verifying Gateway Integration with the Control Plane
- Send a test request to Gateway using
curl
. - Go to Portkey website -> Logs.
- Verify that the test request appears in the logs and that you can view its full details by selecting the log entry.
Uninstalling Portkey Gateway
Setting up Permission
Azure Blob Storage
To allow the Portkey Gateway to access Azure Blob Storage for log storage, permissions must be granted. Follow the steps below to set up these permissions according to your selected access method.- Managed Identity
- Entra Identity
- Specify the details:
- Fetch Identity associated with the AKS cluster.
- Grant identity a role that allows it to access Blob Storage.
Examples
Built-in Redis The following samplevalues.yaml
below shows how to configure the built-in Redis cache and Azure Blob Storage for log store using Entra ID.