Published on

Helm and Kubernetes Naming Conventions

Authors

Today I tried to install a Helm chart using a release name I provided but it failed. Based on this I looked through the Helm naming convention doc as well as the Kubernetes naming conventions.

In the Kubernetes docs on naming it says:

By convention, the names of Kubernetes resources should be up to maximum length of 253 characters and consist of lower case alphanumeric characters, -, and ., but certain resources have more specific restrictions.

I then looked at the Helm documentation which I assumed would have to follow the same conventions or be even more strict as Helm deploys charts to Kubernetes. There it says:

Chart names should be lower case letters and numbers. Words may be separated with dashes (-):


Based on this I played around with a few names and found that the following names fail:

  • -some-name
    • This starts with a dash which is not allowed
  • Some-name
    • You may not use upper case letters at all in Helm
  • 9some-name
    • You cannot start a chart with a number
  • some name
    • You cannot use spaces in your names

The following are perfectly valid names:

  • some-name
  • somename
  • some-name9
    • You can end in a number
  • some--name
    • You can have an arbitrary number of dashes in-between words