1. Deploy the pinot helm chart on Kubernetes

    TypeScript

    To deploy a Helm chart for Apache Pinot on a Kubernetes cluster using Pulumi, you will utilize the kubernetes.helm.v3.Chart resource from the Pulumi Kubernetes provider. This resource represents a Helm chart deployment in a Kubernetes cluster.

    Before we dive into the Pulumi code:

    • Ensure you have Pulumi CLI installed and configured for use with your desired cloud provider.
    • Make sure you have kubectl configured and pointed to the Kubernetes cluster you want to work with.
    • Helm must be installed on your computer, as Pulumi leverages the Helm CLI for Chart deployments.

    Below, you'll find a Pulumi TypeScript program that uses the Chart resource to deploy Apache Pinot's Helm chart. This program assumes that you have the necessary access to a Kubernetes cluster and that the Pinot Helm chart is available in a Helm repository that has been added to your Helm configuration.

    import * as kubernetes from "@pulumi/kubernetes"; // Create a Helm Chart resource to deploy Apache Pinot. const pinotChart = new kubernetes.helm.v3.Chart("apache-pinot", { // Specify the chart repository and name in the `chart` parameter. chart: "pinot", // Provide the Helm repository URL where the Pinot chart is located. fetchOpts: { repo: "https://<helm-repository-url>", }, // If you want to modify the default values or use your values file, // provide the values here as an object or the path to your custom values file. values: { // Custom Apache Pinot values (You can modify this with actual configuration options). cluster: { type: "baremetal", zkAddress: "zookeeper:2181" } }, // Namespace where the Pinot chart should be deployed. namespace: "data-services" }); // When running `pulumi up`, this program will reach out to your currently configured // Kubernetes cluster and deploy Apache Pinot using the Helm chart with specified options. // To access the deployed services, you can output the necessary information. export const pinotChartStatus = pinotChart.status; // Note: `<helm-repository-url>` should be replaced with the actual Helm repository URL // where the Pinot chart is hosted. You can search for the official Helm chart repository // for Apache Pinot or use the one provided by your organization.

    This program defines a Chart resource named apache-pinot using Pulumi's Kubernetes provider. Here's what each section does:

    • chart: Specifies the name of the Helm chart to deploy (in this case, pinot).
    • fetchOpts.repo: Defines the Helm repository URL that contains the Pinot Helm chart you wish to deploy.
    • values: Provides the configuration values for the Helm chart. This is where you could specify your custom configuration settings for the Apache Pinot deployment.
    • namespace: Sets the namespace in Kubernetes where the Pinot services will be deployed.

    To deploy this chart, save the above code in a file named index.ts, then run pulumi up from the command line within the same directory. Pulumi will perform the deployment to your Kubernetes cluster. Make sure to replace <helm-repository-url> with the actual Helm repository URL before running the command.

    For a more in-depth description and available configuration options, you may refer to the Apache Pinot Helm chart documentation and update the values section in the Pulumi program accordingly. Remember, the deployment will also depend on additional factors like your Kubernetes cluster version, network policies, RBAC settings, and so on. Ensure that these settings align with your cluster's configuration.