Helm Dash is a powerful tool designed to simplify the management of Kubernetes applications. It provides a user-friendly interface for deploying and managing charts, making it easier to optimize your Kubernetes setup.
With Helm Dash, you can easily manage multiple charts, track their versions, and monitor their performance. This feature is particularly useful for large-scale applications with many dependencies.
Helm Dash also offers a robust search function, allowing you to quickly find and retrieve specific charts and their associated configurations. This feature saves you time and effort when troubleshooting or making changes to your application.
By leveraging Helm Dash, you can streamline your Kubernetes management process, reducing the complexity and increasing the efficiency of your operations.
Configuration
Configuration is a crucial aspect of running applications in clusters, and Helm Dash makes it easier than ever.
ConfigMaps and Secrets are used for live configuration of applications, allowing you to edit and manage config objects directly in the view.
This feature is particularly useful for managing secrets that are hidden by default, giving you complete control over your application's configuration.
Installation
To install dashboard, you can use a standalone binary, which is the recommended method since version 1.0. It doesn't require Helm or kubectl to be installed.
You can download the appropriate release package for your platform and unpack it to run the dashboard binary. The CLI parameters for the binary can be found in the section below.
The official helm chart is available for installation, but it requires Helm or kubectl to be installed.
To install the dashboard as a Helm plugin, you need to have working helm and kubectl commands, and Helm version 3.4.0+ is required. You can install it by running Helm command, and update it to the latest version by running another Helm command.
The dashboard can be launched by running a specific command, which will start the local Web server and open the UI in a new browser tab. The command will hang waiting for you to terminate it in command-line or web UI.
Config Maps and Secrets
Config Maps and Secrets are essential for live configuration of applications running in clusters.
Config Maps and Secrets in Kubernetes allow for editing and managing config objects, giving you complete control over your application's configuration.
These resources show all the Kubernetes resources used for live configuration, making it easy to identify and manage them.
Config objects are displayed, but Secrets are hidden by default, keeping sensitive information secure.
This feature is particularly useful for developers and administrators who need to manage and update application configurations regularly.
You might like: Live Dash
Usage and Customization
Using Helm Dash is a breeze, especially with the various commands at your disposal. You can run `m-x helm-dash RET` to launch Helm with your active docsets loaded, and typing substrings of what you search will find-as-you-type.
The search starts from 3 chars, which is a great feature to quickly find what you're looking for. You can also install new docsets with `m-x helm-dash-install-docset`, and after installing, add the name of the docset to `helm-dash-common-docsets` or in `helm-dash-docsets`.
Discover more: Dash X
Here's a quick rundown of the default settings:
- helm-dash-min-length is set to 3, which means the search starts from 3 chars.
- helm-dash-browser-func is set to browse-url by default.
- helm-dash-enable-debugging is set to t, which means stderr from sqlite queries is captured and displayed in a buffer.
If you need to clear the connections to all sqlite db's, you can use the command `helm-dash-reset-connections` to do so. This is especially useful in case of errors when adding new docsets.
Uploading a YAML or JSON File
You can define your application in one or more manifests, and upload the files using Dashboard as an alternative to specifying application details in the deploy wizard.
Kubernetes supports declarative configuration, which means all configuration is stored in manifests (YAML or JSON configuration files).
The manifests use Kubernetes API resource schemas, providing a structured way to define your application.
Uploading a YAML or JSON file is a straightforward process, and it's a great way to get started with Kubernetes customization.
You can store all your configuration in manifests, making it easier to manage and maintain your application.
This approach also makes it simple to update your application's configuration, as you only need to modify the relevant manifest files.
Usage and Customization
To use the Helm Dashboard effectively, you'll want to familiarize yourself with its layout and features. The dashboard lists nodes, namespaces, and persistent volumes, with detail views for each.
As an administrator, you can view CPU and memory usage metrics aggregated across all nodes in the node list view. The details view shows metrics for a specific node, including its specification, status, allocated resources, events, and pods running on the node.
You can also switch between multiple clusters with ease, which is a huge time-saver if you manage multiple Kubernetes environments. This feature is particularly useful for troubleshooting and navigating complex cluster setups.
To get the most out of the Helm Dashboard, be sure to explore its key capabilities, including seeing all installed charts and their revision history, as well as browsing Kubernetes resources resulting from the chart.
Here are some of the Helm Dashboard's key features:
- See all installed charts and their revision history
- See manifest diff of the past revisions
- Browse k8s resources resulting from the chart
- Easy rollback or upgrade version with a clear and easy manifest diff
- Integration with popular problem scanners
- Easy switch between multiple clusters
- Can be used locally, or installed into Kubernetes cluster
- Does not require Helm or Kubectl installed
Workloads
When you navigate to the Workloads section, you'll see a list of all applications running in the selected namespace. This view lists applications by workload kind, such as Deployments, ReplicaSets, or StatefulSets.
Each workload kind can be viewed separately, making it easy to focus on the specific type of workload you're interested in. This is particularly helpful when you have a large number of workloads running.
The lists summarize actionable information about the workloads, including the number of ready pods for a ReplicaSet or current memory usage for a Pod. This information is crucial for understanding the health and performance of your workloads.
Detail views for workloads show status and specification information, which can be really useful for troubleshooting issues. For example, you can see which Pods a ReplicaSet is controlling or which ReplicaSets are associated with a Deployment.
Variables to Customize
You can customize helm-dash to suit your preferences by tweaking a few key variables. helm-dash-docsets-path is the prefix for your docsets, and it defaults to ~/.docsets.
If you have a lot of docsets, you might want to consider changing this variable to a more specific location. I've found that keeping my docsets organized in a specific directory makes it easier to manage them.
helm-dash-min-length tells helm-dash from which length to start searching, and it defaults to 3. This means that helm-dash will only start looking for matches once you've typed at least three characters.
You can also customize how helm-dash browses your docsets by changing the helm-dash-browser-func variable. By default, it uses browse-url, but you can switch to something like eww if you prefer.
If you're experiencing slow performance due to stderr from sqlite queries, you can try setting helm-dash-enable-debugging to nil. This will disable capturing stderr, which can speed up queries on some machines.
Controlling Whitespace
Controlling whitespace in templates is crucial for generating correct YAML output. This is because YAML ascribes meaning to whitespace, so managing it becomes pretty important.
The template engine removes the contents inside of {{ and }}, but leaves the remaining whitespace exactly as is. This can lead to incorrect YAML output if not managed properly.
To control whitespace, you can use special characters in the curly brace syntax of template declarations. The dash and space added to the curly braces, {{- and -}}, indicate that whitespace should be chomped left and right, respectively.
Be careful not to confuse {{- (with a space) with {{- (without a space), as they have different effects. For example, {{- 3 }} means "trim left whitespace and print 3", while {{-3 }} means "print -3".
Using the chomping modifiers, you can modify your template to remove unwanted new lines. For instance, the template {{- 3 }} can be used to remove the newline character that would be printed.
It's easy to accidentally consume newlines on both sides, resulting in incorrect YAML output. For example, {{-3 }} will produce "food: "PIZZA"mug: "true" because it consumed newlines on both sides.
To avoid such mistakes, be sure to use the chomping modifiers carefully and make sure there is a space between the dash and the rest of your directive.
Discover more: Space Dash
Looping with Range
In Helm's template language, the way to iterate through a collection is to use the range operator.
The range function will "range over" (iterate through) the list, setting the scope of . to the current item each time through the loop.
Each iteration, . is set to the current item in the list, so the first time it's set to the first item, the second time it's set to the second item, and so on.
You can send the value of . directly down a pipeline, so when you do {{ . | title | quote }}, it sends . to the title function and then to the quote function.
This allows you to easily transform and process the items in the list as you iterate through them.
Using Plugin Manager
To install the dashboard as a Helm plugin, you simply run the Helm command. This will get you up and running with the plugin in no time.
Helm version 3.4.0+ is required to use the plugin, so make sure your machine is updated.
To update the plugin to the latest version, run the same Helm command again. This will ensure you have the most recent features and bug fixes.
The command to start the UI will launch a local web server and open the UI in a new browser tab. Just be aware that the command will hang until you terminate it in the command-line or web UI.
You can see a list of available command-line flags by running helm dashboard --help. This is a great way to explore all the options and customize your experience.
Featured Images: pexels.com