helm v2 mixin

This is a Helm v2 mixin for Porter. It executes the appropriate helm v2 command based on which action it is included within: install, upgrade, or delete.

Source: https://github.com/getporter/helm-mixin

⚠️ Helm v2 is no longer supported. Check out the helm v3 mixin!

Install or Upgrade

porter mixin install helm

Mixin Configuration

Helm client

- helm:
    clientVersion: v2.15.2

Repositories

- helm:
    repositories:
      bitnami:
        url: "https://charts.bitnami.com/bitnami"

Mixin Syntax

Install

install:
- helm:
    description: "Description of the command"
    name: RELEASE_NAME
    chart: STABLE_CHART_NAME
    version: CHART_VERSION
    namespace: NAMESPACE
    replace: BOOL
    devel: BOOL
    wait: BOOL # default true
    set:
      VAR1: VALUE1
      VAR2: VALUE2

Upgrade

upgrade:
- helm:
    description: "Description of the command"
    name: RELEASE_NAME
    chart: STABLE_CHART_NAME
    version: CHART_VERSION
    namespace: NAMESPACE
    resetValues: BOOL
    reuseValues: BOOL
    wait: BOOL # default true
    set:
      VAR1: VALUE1
      VAR2: VALUE2

Uninstall

uninstall:
- helm:
    description: "Description of command"
    purge: BOOL
    releases:
      - RELEASE_NAME1
      - RELASE_NAME2

Outputs

The mixin supports saving secrets from Kuberentes as outputs.

outputs:
    - name: NAME
      secret: SECRET_NAME
      key: SECRET_KEY

The mixin also supports extracting resource metadata from Kubernetes as outputs.

outputs:
    - name: NAME
      resourceType: RESOURCE_TYPE
      resourceName: RESOURCE_TYPE_NAME
      namespace: NAMESPACE
      jsonPath: JSON_PATH_DEFINITION

Examples

Install

install:
- helm:
    description: "Install MySQL"
    name: mydb
    chart: bitnami/mysql
    version: 6.14.2
    namespace: mydb
    replace: true
    set:
      db.name: wordpress
      db.user: wordpress
    outputs:
      - name: mysql-root-password
        secret: mydb-mysql
        key: mysql-root-password
      - name: mysql-password
        secret: mydb-mysql
        key: mysql-password
      - name: mysql-cluster-ip
        resourceType: service
        resourceName: porter-ci-mysql-service
        namespace: "default"
        jsonPath: "{.spec.clusterIP}"

Upgrade

upgrade:
- helm:
    description: "Upgrade MySQL"
    name: porter-ci-mysql
    chart: bitnami/mysql
    version: 6.14.2
    wait: true
    resetValues: true
    reuseValues: false
    set:
      db.name: mydb
      db.user: myuser
      livenessProbe.initialDelaySeconds: 30
      persistence.enabled: true

Uninstall

uninstall:
- helm:
    description: "Uninstall MySQL"
    purge: true
    releases:
      - mydb