From e6c42befe69b46726f8dccc5e85857b7e99a7c87 Mon Sep 17 00:00:00 2001 From: GuyTempleton Date: Mon, 9 Nov 2020 22:40:20 +0000 Subject: [PATCH] Restore Cluster Autoscaler Chart name to cluster-autoscaler Update helm/chart-releaser action to achieve this --- .github/workflows/release.yaml | 14 ++++++++--- .../.helmignore | 0 .../Chart.yaml | 4 +-- .../README.md | 25 +++++++++++++------ .../README.md.gotmpl | 23 +++++++++++------ .../templates/NOTES.txt | 0 .../templates/_helpers.tpl | 0 .../templates/clusterrole.yaml | 0 .../templates/clusterrolebinding.yaml | 0 .../templates/deployment.yaml | 0 .../templates/pdb.yaml | 0 .../templates/podsecuritypolicy.yaml | 0 .../priority-expander-configmap.yaml | 0 .../templates/role.yaml | 0 .../templates/rolebinding.yaml | 0 .../templates/secret.yaml | 0 .../templates/service.yaml | 0 .../templates/serviceaccount.yaml | 0 .../templates/servicemonitor.yaml | 0 .../values.yaml | 0 20 files changed, 46 insertions(+), 20 deletions(-) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/.helmignore (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/Chart.yaml (92%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/README.md (93%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/README.md.gotmpl (89%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/NOTES.txt (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/_helpers.tpl (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/clusterrole.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/clusterrolebinding.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/deployment.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/pdb.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/podsecuritypolicy.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/priority-expander-configmap.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/role.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/rolebinding.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/secret.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/service.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/serviceaccount.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/templates/servicemonitor.yaml (100%) rename charts/{cluster-autoscaler-chart => cluster-autoscaler}/values.yaml (100%) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index ba147c59b2a1..15fa1c251978 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -4,16 +4,24 @@ jobs: steps: - name: Checkout uses: actions/checkout@v2 - - name: Fetch history - run: git fetch --prune --unshallow + with: + fetch-depth: 0 + - name: Configure Git run: | git config user.name "${GITHUB_ACTOR}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" + + - name: Install Helm + uses: azure/setup-helm@v1 + with: + version: v3.4.0 + - env: CR_TOKEN: ${{ secrets.GITHUB_TOKEN }} + CR_RELEASE_NAME_TEMPLATE: "cluster-autoscaler-chart-{{ .Version }}" name: Run chart-releaser - uses: helm/chart-releaser-action@v1.0.0-rc.2 + uses: helm/chart-releaser-action@v1.1.0 name: Release Charts on: push: diff --git a/charts/cluster-autoscaler-chart/.helmignore b/charts/cluster-autoscaler/.helmignore similarity index 100% rename from charts/cluster-autoscaler-chart/.helmignore rename to charts/cluster-autoscaler/.helmignore diff --git a/charts/cluster-autoscaler-chart/Chart.yaml b/charts/cluster-autoscaler/Chart.yaml similarity index 92% rename from charts/cluster-autoscaler-chart/Chart.yaml rename to charts/cluster-autoscaler/Chart.yaml index 4f86dcc4dfe0..19c0b5f76122 100644 --- a/charts/cluster-autoscaler-chart/Chart.yaml +++ b/charts/cluster-autoscaler/Chart.yaml @@ -13,8 +13,8 @@ maintainers: name: gjtempleton - email: scott.crooks@gmail.com name: sc250024 -name: cluster-autoscaler-chart +name: cluster-autoscaler sources: - https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler type: application -version: 1.1.1 +version: 9.0.0 diff --git a/charts/cluster-autoscaler-chart/README.md b/charts/cluster-autoscaler/README.md similarity index 93% rename from charts/cluster-autoscaler-chart/README.md rename to charts/cluster-autoscaler/README.md index a4c162d381fc..a93e628e4384 100644 --- a/charts/cluster-autoscaler-chart/README.md +++ b/charts/cluster-autoscaler/README.md @@ -1,4 +1,4 @@ -# cluster-autoscaler-chart +# cluster-autoscaler Scales Kubernetes worker nodes within autoscaling groups. @@ -8,11 +8,11 @@ Scales Kubernetes worker nodes within autoscaling groups. $ helm repo add autoscaler https://kubernetes.github.io/autoscaler # Method 1 - Using Autodiscovery -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set 'autoDiscovery.clusterName'= # Method 2 - Specifying groups manually -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroups[0].name=your-asg-name" \ --set "autoscalingGroups[0].maxSize=10" \ --set "autoscalingGroups[0].minSize=1" @@ -35,7 +35,16 @@ This chart bootstraps a cluster-autoscaler deployment on a [Kubernetes](http://k The previous `cluster-autoscaler` Helm chart hosted at [helm/charts](https://github.com/helm/charts) has been moved to this repository in accordance with the [Deprecation timeline](https://github.com/helm/charts#deprecation-timeline). Note that a few things have changed between this version and the old version: - This repository **only** supports Helm chart installations using Helm 3+ since the `apiVersion` on the charts has been marked as `v2`. -- Previous versions of the Helm chart have not been migrated, and the version was reset to `1.0.0` at the onset. If you are looking for old versions of the chart, it's best to run `helm pull stable/cluster-autoscaler --version ` until you are ready to move to this repository's version. +- Previous versions of the Helm chart have not been migrated, and the version was reset to `1.0.0` initially. If you are looking for old versions of the chart, it's best to run `helm pull stable/cluster-autoscaler --version ` until you are ready to move to this repository's version. +- The previous versioning scheme has been returned to as of version `9.0.0` for ease of migration from the previous chart location. + +## Migration from 1.X to 9.X+ versions of this Chart + +On initial adoption of this chart this chart was renamed from `cluster-autoscaler` to `cluster-autoscaler-chart` due to technical limitations. This affects all `1.X` releases of the chart. + +Releases of the chart from `9.0.0` onwards return the naming of the chart to `cluster-autoscaler` and return to following the versioning established by the chart's previous location. + +To migrate from a 1.X release of the chart to a `9.0.0` or later release, you should first uninstall your `1.X` install of the `cluster-autoscaler-chart` chart, before performing the installation of the new `cluster-autoscaler` chart. ## Installing the Chart @@ -66,7 +75,7 @@ Auto-discovery finds ASGs tags as below and automatically manages them based on - Set `awsAccessKeyID=` and `awsSecretAccessKey=` if you want to [use AWS credentials directly instead of an instance role](https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/cloudprovider/aws/README.md#using-aws-credentials) ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart --set autoDiscovery.clusterName= +$ helm install my-release autoscaler/cluster-autoscaler --set autoDiscovery.clusterName= ``` #### Specifying groups manually @@ -77,7 +86,7 @@ Without autodiscovery, specify an array of elements each containing ASG name, mi - Either provide a yaml file setting `autoscalingGroups` (see values.yaml) or use `--set` e.g.: ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroups[0].name=your-asg-name" \ --set "autoscalingGroups[0].maxSize=10" \ --set "autoscalingGroups[0].minSize=1" @@ -138,7 +147,7 @@ The following parameters are required: To use Managed Instance Group (MIG) auto-discovery, provide a YAML file setting `autoscalingGroupsnamePrefix` (see values.yaml) or use `--set` when installing the Chart - e.g. ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroupsnamePrefix[0].name=your-ig-prefix,autoscalingGroupsnamePrefix[0].maxSize=10,autoscalingGroupsnamePrefi[0].minSize=1" \ --set autoDiscovery.clusterName= \ --set cloudProvider=gce @@ -183,7 +192,7 @@ Example values files can be found [here](../../cluster-autoscaler/cloudprovider/ Install the chart with ``` -$ helm install my-release autoscaler/cluster-autoscaler-chart -f myvalues.yaml +$ helm install my-release autoscaler/cluster-autoscaler -f myvalues.yaml ``` ## Uninstalling the Chart diff --git a/charts/cluster-autoscaler-chart/README.md.gotmpl b/charts/cluster-autoscaler/README.md.gotmpl similarity index 89% rename from charts/cluster-autoscaler-chart/README.md.gotmpl rename to charts/cluster-autoscaler/README.md.gotmpl index ea23e5083568..29b52e46171f 100644 --- a/charts/cluster-autoscaler-chart/README.md.gotmpl +++ b/charts/cluster-autoscaler/README.md.gotmpl @@ -8,11 +8,11 @@ $ helm repo add autoscaler https://kubernetes.github.io/autoscaler # Method 1 - Using Autodiscovery -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set 'autoDiscovery.clusterName'= # Method 2 - Specifying groups manually -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroups[0].name=your-asg-name" \ --set "autoscalingGroups[0].maxSize=10" \ --set "autoscalingGroups[0].minSize=1" @@ -35,7 +35,16 @@ This chart bootstraps a cluster-autoscaler deployment on a [Kubernetes](http://k The previous `cluster-autoscaler` Helm chart hosted at [helm/charts](https://github.com/helm/charts) has been moved to this repository in accordance with the [Deprecation timeline](https://github.com/helm/charts#deprecation-timeline). Note that a few things have changed between this version and the old version: - This repository **only** supports Helm chart installations using Helm 3+ since the `apiVersion` on the charts has been marked as `v2`. -- Previous versions of the Helm chart have not been migrated, and the version was reset to `1.0.0` at the onset. If you are looking for old versions of the chart, it's best to run `helm pull stable/cluster-autoscaler --version ` until you are ready to move to this repository's version. +- Previous versions of the Helm chart have not been migrated, and the version was reset to `1.0.0` initially. If you are looking for old versions of the chart, it's best to run `helm pull stable/cluster-autoscaler --version ` until you are ready to move to this repository's version. +- The previous versioning scheme has been returned to as of version `9.0.0` for ease of migration from the previous chart location. + +## Migration from 1.X to 9.X+ versions of this Chart + +On initial adoption of this chart this chart was renamed from `cluster-autoscaler` to `cluster-autoscaler-chart` due to technical limitations. This affects all `1.X` releases of the chart. + +Releases of the chart from `9.0.0` onwards return the naming of the chart to `cluster-autoscaler` and return to following the versioning established by the chart's previous location. + +To migrate from a 1.X release of the chart to a `9.0.0` or later release, you should first uninstall your `1.X` install of the `cluster-autoscaler-chart` chart, before performing the installation of the new `cluster-autoscaler` chart. ## Installing the Chart @@ -66,7 +75,7 @@ Auto-discovery finds ASGs tags as below and automatically manages them based on - Set `awsAccessKeyID=` and `awsSecretAccessKey=` if you want to [use AWS credentials directly instead of an instance role](https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/cloudprovider/aws/README.md#using-aws-credentials) ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart --set autoDiscovery.clusterName= +$ helm install my-release autoscaler/cluster-autoscaler --set autoDiscovery.clusterName= ``` #### Specifying groups manually @@ -77,7 +86,7 @@ Without autodiscovery, specify an array of elements each containing ASG name, mi - Either provide a yaml file setting `autoscalingGroups` (see values.yaml) or use `--set` e.g.: ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroups[0].name=your-asg-name" \ --set "autoscalingGroups[0].maxSize=10" \ --set "autoscalingGroups[0].minSize=1" @@ -138,7 +147,7 @@ The following parameters are required: To use Managed Instance Group (MIG) auto-discovery, provide a YAML file setting `autoscalingGroupsnamePrefix` (see values.yaml) or use `--set` when installing the Chart - e.g. ```console -$ helm install my-release autoscaler/cluster-autoscaler-chart \ +$ helm install my-release autoscaler/cluster-autoscaler \ --set "autoscalingGroupsnamePrefix[0].name=your-ig-prefix,autoscalingGroupsnamePrefix[0].maxSize=10,autoscalingGroupsnamePrefi[0].minSize=1" \ --set autoDiscovery.clusterName= \ --set cloudProvider=gce @@ -183,7 +192,7 @@ Example values files can be found [here](../../cluster-autoscaler/cloudprovider/ Install the chart with ``` -$ helm install my-release autoscaler/cluster-autoscaler-chart -f myvalues.yaml +$ helm install my-release autoscaler/cluster-autoscaler -f myvalues.yaml ``` ## Uninstalling the Chart diff --git a/charts/cluster-autoscaler-chart/templates/NOTES.txt b/charts/cluster-autoscaler/templates/NOTES.txt similarity index 100% rename from charts/cluster-autoscaler-chart/templates/NOTES.txt rename to charts/cluster-autoscaler/templates/NOTES.txt diff --git a/charts/cluster-autoscaler-chart/templates/_helpers.tpl b/charts/cluster-autoscaler/templates/_helpers.tpl similarity index 100% rename from charts/cluster-autoscaler-chart/templates/_helpers.tpl rename to charts/cluster-autoscaler/templates/_helpers.tpl diff --git a/charts/cluster-autoscaler-chart/templates/clusterrole.yaml b/charts/cluster-autoscaler/templates/clusterrole.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/clusterrole.yaml rename to charts/cluster-autoscaler/templates/clusterrole.yaml diff --git a/charts/cluster-autoscaler-chart/templates/clusterrolebinding.yaml b/charts/cluster-autoscaler/templates/clusterrolebinding.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/clusterrolebinding.yaml rename to charts/cluster-autoscaler/templates/clusterrolebinding.yaml diff --git a/charts/cluster-autoscaler-chart/templates/deployment.yaml b/charts/cluster-autoscaler/templates/deployment.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/deployment.yaml rename to charts/cluster-autoscaler/templates/deployment.yaml diff --git a/charts/cluster-autoscaler-chart/templates/pdb.yaml b/charts/cluster-autoscaler/templates/pdb.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/pdb.yaml rename to charts/cluster-autoscaler/templates/pdb.yaml diff --git a/charts/cluster-autoscaler-chart/templates/podsecuritypolicy.yaml b/charts/cluster-autoscaler/templates/podsecuritypolicy.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/podsecuritypolicy.yaml rename to charts/cluster-autoscaler/templates/podsecuritypolicy.yaml diff --git a/charts/cluster-autoscaler-chart/templates/priority-expander-configmap.yaml b/charts/cluster-autoscaler/templates/priority-expander-configmap.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/priority-expander-configmap.yaml rename to charts/cluster-autoscaler/templates/priority-expander-configmap.yaml diff --git a/charts/cluster-autoscaler-chart/templates/role.yaml b/charts/cluster-autoscaler/templates/role.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/role.yaml rename to charts/cluster-autoscaler/templates/role.yaml diff --git a/charts/cluster-autoscaler-chart/templates/rolebinding.yaml b/charts/cluster-autoscaler/templates/rolebinding.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/rolebinding.yaml rename to charts/cluster-autoscaler/templates/rolebinding.yaml diff --git a/charts/cluster-autoscaler-chart/templates/secret.yaml b/charts/cluster-autoscaler/templates/secret.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/secret.yaml rename to charts/cluster-autoscaler/templates/secret.yaml diff --git a/charts/cluster-autoscaler-chart/templates/service.yaml b/charts/cluster-autoscaler/templates/service.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/service.yaml rename to charts/cluster-autoscaler/templates/service.yaml diff --git a/charts/cluster-autoscaler-chart/templates/serviceaccount.yaml b/charts/cluster-autoscaler/templates/serviceaccount.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/serviceaccount.yaml rename to charts/cluster-autoscaler/templates/serviceaccount.yaml diff --git a/charts/cluster-autoscaler-chart/templates/servicemonitor.yaml b/charts/cluster-autoscaler/templates/servicemonitor.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/templates/servicemonitor.yaml rename to charts/cluster-autoscaler/templates/servicemonitor.yaml diff --git a/charts/cluster-autoscaler-chart/values.yaml b/charts/cluster-autoscaler/values.yaml similarity index 100% rename from charts/cluster-autoscaler-chart/values.yaml rename to charts/cluster-autoscaler/values.yaml