diff --git a/stable/spartakus/.helmignore b/stable/spartakus/.helmignore new file mode 100644 index 0000000000..f0c1319444 --- /dev/null +++ b/stable/spartakus/.helmignore @@ -0,0 +1,21 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*~ +# Various IDEs +.project +.idea/ +*.tmproj diff --git a/stable/spartakus/Chart.yaml b/stable/spartakus/Chart.yaml new file mode 100755 index 0000000000..489d4a7383 --- /dev/null +++ b/stable/spartakus/Chart.yaml @@ -0,0 +1,9 @@ +name: spartakus +version: 1.0.0 +description: A Spartakus Helm chart for Kubernetes. Spartakus aims to collect information about Kubernetes clusters. +sources: + - https://github.com/kubernetes-incubator/spartakus +maintainers: + - name: Michael Goodness + email: mgoodness@gmail.com +engine: gotpl diff --git a/stable/spartakus/README.md b/stable/spartakus/README.md new file mode 100644 index 0000000000..b5934408ed --- /dev/null +++ b/stable/spartakus/README.md @@ -0,0 +1,67 @@ +# Spartakus + +[Spartakus](https://github.com/kubernetes-incubator/spartakus) aims to collect information about Kubernetes clusters. This information will help the Kubernetes development team to understand what people are doing with it, and to make it a better product. + +## TL;DR; + +```console +$ helm install stable/spartakus +``` + +## Introduction + +This chart bootstraps a [Spartakus](https://github.com/kubernetes-incubator/spartakus) deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +## Prerequisites + +- Kubernetes 1.3+ with Beta APIs enabled + +## Installing the Chart + +To install the chart with the release name `my-release`: + +```console +$ helm install --name my-release stable/spartakus +``` + +The command deploys Spartakus on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists the parameters that can be configured during installation. + +> **Tip**: List all releases using `helm list` + +## Uninstalling the Chart + +To uninstall/delete the `my-release` deployment: + +```console +$ helm delete my-release +``` + +The command removes all the Kubernetes components associated with the chart and deletes the release. + +## Configuration + +The following tables lists the configurable parameters of the Spartakus chart and their default values. + +| Parameter | Description | Default | +| ------------------------------- | ------------------------------- | ---------------------------------------------------------- | +| `image` | Spartakus image | `gcr.io/google_containers/spartakus-amd64:{VERSION}` | +| `imagePullPolicy` | Image pull policy | `Always` if `image` tag is `latest`, else `IfNotPresent` | +| `resources.requests.cpu` | CPU resource request | `1m` | +| `resources.requests.memory` | Memory resource request | `8Mi` | +| `uuid` | Unique cluster ID | Dynamically-generated using `uuidv4` template function | + +Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, + +```console +$ helm install --name my-release \ + --set uuid=19339C6E-FD73-4787-BFD8-F710C8D8364E \ + stable/spartakus +``` + +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, + +```console +$ helm install --name my-release -f values.yaml stable/spartakus +``` + +> **Tip**: You can use the default [values.yaml](values.yaml) diff --git a/stable/spartakus/templates/NOTES.txt b/stable/spartakus/templates/NOTES.txt new file mode 100644 index 0000000000..e264fd46f8 --- /dev/null +++ b/stable/spartakus/templates/NOTES.txt @@ -0,0 +1,7 @@ +Spartakus is now running in your cluster. + +THIS DOES NOT REPORT ANY PERSONAL INFORMATION. Anything that might be identifying, including things +like IP addresses, container images, and object names are anonymized. We take this very seriously. +If you think something we are collecting might be considered personal information, PLEASE let us know! + +https://github.com/kubernetes-incubator/spartakus diff --git a/stable/spartakus/templates/_helpers.tpl b/stable/spartakus/templates/_helpers.tpl new file mode 100644 index 0000000000..234480de71 --- /dev/null +++ b/stable/spartakus/templates/_helpers.tpl @@ -0,0 +1,16 @@ +{{/* vim: set filetype=mustache: */}} +{{/* +Expand the name of the chart. +*/}} +{{- define "name" -}} +{{- default .Chart.Name .Values.nameOverride | trunc 24 -}} +{{- end -}} + +{{/* +Create a default fully qualified app name. +We truncate at 24 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). +*/}} +{{- define "fullname" -}} +{{- $name := default .Chart.Name .Values.nameOverride -}} +{{- printf "%s-%s" .Release.Name $name | trunc 24 -}} +{{- end -}} diff --git a/stable/spartakus/templates/deployment.yaml b/stable/spartakus/templates/deployment.yaml new file mode 100644 index 0000000000..603ac66510 --- /dev/null +++ b/stable/spartakus/templates/deployment.yaml @@ -0,0 +1,26 @@ +apiVersion: extensions/v1beta1 +kind: Deployment +metadata: + labels: + app: {{ template "fullname" . }} + chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" + heritage: "{{ .Release.Service }}" + release: "{{ .Release.Name }}" + name: {{ template "fullname" . }} +spec: + replicas: 1 + template: + metadata: + labels: + app: {{ template "fullname" . }} + release: "{{ .Release.Name }}" + spec: + containers: + - name: {{ template "fullname" . }} + image: "{{ .Values.image }}" + imagePullPolicy: {{ default "" .Values.imagePullPolicy | quote }} + args: + - volunteer + - --cluster-id={{ uuidv4 | default .Values.uuid | quote }} + resources: +{{ toYaml .Values.resources | indent 12 }} diff --git a/stable/spartakus/values.yaml b/stable/spartakus/values.yaml new file mode 100644 index 0000000000..3273a339ff --- /dev/null +++ b/stable/spartakus/values.yaml @@ -0,0 +1,23 @@ +image: gcr.io/google_containers/spartakus-amd64:v1.0.0 + +## Specify a imagePullPolicy +## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' +## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images +## +# imagePullPolicy: + +## Configure resource requests and limits +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: + # limits: + # cpu: 2m + # memory: 8Mi + requests: + cpu: 2m + memory: 8Mi + +## A version 4 UUID to uniquely identify the cluster +## If not provided, Helm will generate automatically at install-time. +## +# uuid: