Use helm in Kubernetes

Helm is the package manager for Kubernetes, you can think it as yum/apt/homebrew. It contains two parts: Server (tiller) and Client (helm). helm client can be installed on Linux/Mac/Windows, the package can be found here.

Helm manages the Kubernetes charts which are pre-configured Kubernetes resources. In the following example, I will show you how to install Prometheus by using helm.

    1. Setup RABC for helm (tiller) to use, the sample config file:
      apiVersion: v1
      kind: ServiceAccount
        name: tiller
        namespace: kube-system
      kind: ClusterRoleBinding
        name: tiller
        kind: ClusterRole
        name: cluster-admin
        - kind: ServiceAccount
          name: tiller
          namespace: kube-system
    2. Initialize helm and update repository
      helm init --service-account tiller
      helm repo update
    3. Install Prometheus and configure the ingress for the services. I use the Kubernetes cluster that is built by kops, and I will continue use the example domain Please change it accordingly.
      helm install stable/Prometheus \
      --set alertmanager.ingress.enabled=true \
      --set "alertmanager.ingress.hosts={}" \
      --set pushgateway.ingress.enabled=true \
      --set "pushgateway.ingress.hosts={}" \
      --set server.ingress.enabled=true \
      --set "server.ingress.hosts={}"
    4. If you installed it successfully, it should like this:
    5. Add alias records in Route 53 for and other services to point to ELB. Then test it, you should see the Prometheus page.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s