Skip to content

Latest commit

 

History

History
120 lines (79 loc) · 5.81 KB

installation.md

File metadata and controls

120 lines (79 loc) · 5.81 KB

Installation

Requirements

AKS

You need an AKS cluster (create an AKS cluster instructions) or any other Kubernetes cluster (version 1.21.2 or newer - tested and verified with version 1.21.2. and a minimum of 3 node count).

You need to be able to connect to your cluster from your machine.

During the cluster creation, the cluster infrastructure authentication specified is used by Azure Kubernetes Service to manage cloud resources attached to the cluster.

This can be either a service principal or a system-assigned managed identity.

If you choose to use a service principal, you will need to:

If you choose to use a sytem assigned identity, you will need to:

Azure Data Explorer (ADX)

You need a running ADX instance. This instance will be the main entry point for retrieving metrics and aggregations from K2Bridge.
You need the ADX Cluster URL and the database name.

Regarding the authorization needed to access ADX from K2Bridge, you need to set cluster's view permissions for :

  • The Azure AD service principal, if you've choosed to use a service principal to authenticate your AKS cluster
  • The System Assigned Managed Identity, if you've choose the System Assigned Managed Identity to authenticate your AKS cluster.

Instructions on how to set cluster's view permissions for the Azure AD service principal or the System assigned managed identity, can be found here: Manage permissions

Tooling

To be able to deploy K2Bridge in your AKS cluster, you need Helm 3.

Optionaly, you may want to use Docker to build the image. If you need to build the image, please follow the build instructions.

Run on Azure Kubernetes Service (AKS)

  1. By default, K2's Helm chart references a publicly available image located on Microsoft's Container Registry (MCR) which does not require any credentials and work out of the box.

  2. Download the required Helm charts

    1. Add the Elasticsearch dependency to Helm:

      helm repo add elastic https://helm.elastic.co
      helm repo update
    2. The K2 chart is located under the charts directory. Clone the repository to get the chart.

      1. go to the K2 root repository directory

      2. run

        helm dependency update charts/k2bridge
  3. Deploy

    • Recommended - create a kubernetes namespace.
      This namespace is later passed to helm install via the -n switch.
    kubectl create namespace k2bridge
    • Set a few variables with the correct values for your environment:

      ADX_URL=[YOUR_ADX_CLUSTER_URL e.g. https://mycluster.westeurope.kusto.windows.net]
      ADX_DATABASE=[YOUR_ADX_DATABASE_NAME]
      ADX_CLIENT_ID=[SERVICE_PRINCIPAL_CLIENT_ID]
      ADX_TENANT_ID=[SERVICE_PRINCIPAL_TENANT_ID]

      Note: when using managed identity, the ADX_CLIENT_ID value is the client id of the managed identity

      Optional - provide ADX SP Client secret

      ADX_CLIENT_SECRET=[SERVICE_PRINCIPAL_CLIENT_SECRET]

      Optional - enable ApplicationInsights telemetry

      APPLICATION_INSIGHTS_KEY=[INSTRUMENTATION_KEY]
      COLLECT_TELEMETRY=true
      helm install k2bridge charts/k2bridge -n k2bridge --set settings.adxClusterUrl="$ADX_URL" --set settings.adxDefaultDatabaseName="$ADX_DATABASE" --set settings.aadClientId="$ADX_CLIENT_ID" --set settings.aadClientSecret="$ADX_CLIENT_SECRET" --set settings.aadTenantId="$ADX_TENANT_ID" [--set image.tag=7.16_latest] [--set settings.collectTelemetry=$COLLECT_TELEMETRY]

      OR (if managed identity was set)

      helm install k2bridge charts/k2bridge -n k2bridge --set settings.adxClusterUrl="$ADX_URL" --set settings.adxDefaultDatabaseName="$ADX_DATABASE" --set settings.aadClientId="$ADX_CLIENT_ID" --set settings.useManagedIdentity=true --set settings.aadTenantId="$ADX_TENANT_ID" [--set image.tag=7.16_latest] [--set settings.collectTelemetry=$COLLECT_TELEMETRY]

      The complete set of configuration options can be found here.

    • Deploy Kibana
      The command output will suggest a helm command to run to deploy Kibana, similar to:

      helm install kibana elastic/kibana --version 7.17.3 -n k2bridge --set image=docker.elastic.co/kibana/kibana-oss --set imageTag=7.10.2 --set elasticsearchHosts=http://k2bridge:8080
  4. Configure index-patterns
    In a new installation of Kibana, you will need to configure the index-patterns to access your data. Navigate to Management -> Index Patterns -> Create index pattern. Note that the name of the index must be an exact match to the table name or function name, without any asterisk. You can copy the relevant line from the list.

Notes: To run on other kubernetes providers, change in values.yaml the elasticsearch storageClassName to fit the one suggested by the provider.