Skip to content
This repository was archived by the owner on Feb 22, 2022. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions stable/acs-engine-autoscaler/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ apiVersion: v1
description: Scales worker nodes within agent pools
icon: https://github.com/kubernetes/kubernetes/blob/master/logo/logo.png
name: acs-engine-autoscaler
version: 1.0.0
version: 2.0.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this really need to be a major version change? Doesn't seem to be breaking.

Copy link
Contributor Author

@kevinschumacher kevinschumacher Sep 7, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO we are changing the chart's API in a breaking way by changing the names of defined template functions.

Example:
subchart1 defines fullname
parent, which depends on subchart1, uses the fullname template function (it's global) in a configmap (or other resource) like {{ template "fullname" . }}

subchart1, in a minor version release, has the global defined template names changed from fullname to subchart1.fullname.

author of parent updates dependency, tries to deploy, and parent's configmap won't render because there is no longer a template function fullname (it's now subchart1.fullname)

sources:
- https://github.com/wbuchwalter/Kubernetes-acs-engine-autoscaler
- https://github.com/wbuchwalter/Kubernetes-acs-engine-autoscaler
maintainers:
- name: Rita Zhang
email: [email protected]
- name: William Buchwalter
email: [email protected]
- name: Rita Zhang
email: [email protected]
- name: William Buchwalter
email: [email protected]
4 changes: 2 additions & 2 deletions stable/acs-engine-autoscaler/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ The acs-engine-autoscaler is getting provisioned in your cluster. After a few mi

To verify that acs-engine-autoscaler has started, run:

kubectl --namespace={{ .Release.Namespace }} get pods -l "app={{ template "name" . }}"
kubectl --namespace={{ .Release.Namespace }} get pods -l "app={{ template "acs-engine-autoscaler.name" . }}"

To verify that acs-engine-autoscaler is running as expected, run:
kubectl logs $(kubectl --namespace={{ .Release.Namespace }} get pods -l "app={{ template "name" . }}" -o jsonpath="{.items[0].metadata.name}")
kubectl logs $(kubectl --namespace={{ .Release.Namespace }} get pods -l "app={{ template "acs-engine-autoscaler.name" . }}" -o jsonpath="{.items[0].metadata.name}")

{{- else -}}
##############################################################################
Expand Down
12 changes: 6 additions & 6 deletions stable/acs-engine-autoscaler/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "name" -}}
{{- define "acs-engine-autoscaler.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
{{- end -}}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "fullname" -}}
{{- define "acs-engine-autoscaler.fullname" -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
Expand All @@ -21,11 +21,11 @@ https://github.com/technosophos/common-chart/
labels.standard prints the standard Helm labels.
The standard labels are frequently used in metadata.
*/ -}}
{{- define "labels.standard" -}}
app: {{ template "name" . }}
{{- define "acs-engine-autoscaler.labels.standard" -}}
app: {{ template "acs-engine-autoscaler.name" . }}
heritage: {{ .Release.Service | quote }}
release: {{ .Release.Name | quote }}
chart: {{ template "chartref" . }}
chart: {{ template "acs-engine-autoscaler.chartref" . }}
{{- end -}}

{{- /*
Expand All @@ -37,6 +37,6 @@ Example output:
zookeeper-1.2.3
wordpress-3.2.1_20170219
*/ -}}
{{- define "chartref" -}}
{{- define "acs-engine-autoscaler.chartref" -}}
{{- replace "+" "_" .Chart.Version | printf "%s-%s" .Chart.Name -}}
{{- end -}}
20 changes: 10 additions & 10 deletions stable/acs-engine-autoscaler/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,50 +2,50 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
labels:
{{ include "labels.standard" . | indent 4 }}
{{ include "acs-engine-autoscaler.labels.standard" . | indent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
template:
metadata:
labels:
{{ include "labels.standard" . | indent 8 }}
{{ include "acs-engine-autoscaler.labels.standard" . | indent 8 }}
openai/do-not-drain: "true"
spec:
containers:
- name: {{ template "fullname" . }}
- name: {{ template "acs-engine-autoscaler.fullname" . }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
env:
- name: AZURE_SP_APP_ID
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: azure-sp-app-id
- name: AZURE_SP_SECRET
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: azure-sp-secret
- name: AZURE_SP_TENANT_ID
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: azure-sp-tenant-id
- name: KUBECONFIG_PRIVATE_KEY
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: kubeconfig-private-key
- name: CLIENT_PRIVATE_KEY
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: client-private-key
- name: CA_PRIVATE_KEY
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
key: ca-private-key
command:
- python
Expand Down
4 changes: 2 additions & 2 deletions stable/acs-engine-autoscaler/templates/secrets.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
apiVersion: v1
kind: Secret
metadata:
name: {{ template "fullname" . }}
name: {{ template "acs-engine-autoscaler.fullname" . }}
labels:
{{ include "labels.standard" . | indent 4 }}
{{ include "acs-engine-autoscaler.labels.standard" . | indent 4 }}
type: Opaque
data:
azure-sp-app-id: {{ default "MISSING" .Values.acsenginecluster.azurespappid | b64enc | quote }}
Expand Down