Deploy the kyuubi helm chart on Kubernetes
TypeScriptTo deploy the Kyuubi Helm chart on Kubernetes using Pulumi, you will typically perform the following steps:
- Set up your Pulumi environment: Ensure you are authenticated with a Pulumi account and your chosen Kubernetes cluster.
- Install the necessary Pulumi packages: Install the Kubernetes package for TypeScript using
npm
oryarn
. - Create a Pulumi program: Write a TypeScript program that defines the Kubernetes resources you want to deploy, including the Helm chart for Kyuubi.
Let's start by setting up a new Pulumi project:
pulumi new typescript
Once you run this command, Pulumi will walk you through creating a new project.
Next, install the necessary Pulumi Kubernetes package:
npm install @pulumi/kubernetes
Now, you can define the Kubernetes resources necessary to deploy the Kyuubi Helm chart. The
@pulumi/kubernetes
package allows us to interact with Kubernetes resources, including deploying Helm charts.Below is the TypeScript program that uses Pulumi to deploy the Kyuubi Helm chart on Kubernetes. Note that you need to have Helm and Kyuubi chart details, such as the repository URL, chart name, and any custom values you wish to configure.
For the purpose of this example, let's assume the chart is hosted in a hypothetical Helm repository at
https://helm.kyuubi.com
. The actual chart name and values would depend on Kyuubi's Helm chart specifics, which you should change accordingly.import * as k8s from "@pulumi/kubernetes"; // Define the Helm chart for Kyuubi. Replace the `repo` and `chart` values with correct ones for Kyuubi. const kyuubiChart = new k8s.helm.v3.Chart("kyuubi", { repo: "kyuubi-repo", // The repository name where the Kyuubi chart is located chart: "kyuubi", // The name of the chart you want to deploy version: "1.0.0", // The version of the chart you want to deploy // Add any custom values file or configuration in the below section values: { // Example configuration values. Replace them with the appropriate Kyuubi configuration. // These values depend on the values.yaml provided with the Helm chart. // You can set them according to the needs of your deployment. service: { type: "LoadBalancer", port: 10009, }, persistence: { enabled: true, size: "10Gi", }, authentication: { method: "NONE", // NONE, LDAP, etc. }, // ...other values... }, }); // Export the necessary details if needed. export const kyuubiServiceName = kyuubiChart.getResourceProperty("v1/Service", "kyuubi", "metadata").apply(m => m.name); export const kyuubiServiceUrl = kyuubiChart.getResourceProperty("v1/Service", "kyuubi", "status").apply(s => s.loadBalancer.ingress[0].hostname || s.loadBalancer.ingress[0].ip);
This program initializes a Helm chart resource for Kyuubi and applies custom values to it. It's assuming you have a
Service
resource part of your Helm deployment which is exposed through a LoadBalancer. If your actual template has different resources or configuration parameters, modify yourvalues
field accordingly.After deploying the above Pulumi program with
pulumi up
, the command line will show status updates as Pulumi executes the deployment steps. Once complete, it will output any exported values such as service name and url. You can access your Kyuubi service using the load balancer URL or IP provided in the outputs.Remember to replace the placeholders in the
repo
andchart
fields with the actual values for the Kyuubi chart you are deploying.To properly manage resources, use Pulumi's stack management system (
pulumi stack
) to cleanly create, update, or destroy Kubernetes resources defined in your program.