Skip to content
This repository was archived by the owner on Nov 7, 2019. It is now read-only.

Commit d1d2eef

Browse files
author
Christopher Hein
authored
Merge pull request #113 from acaire/add_helm_chart
Add helm chart
2 parents 3f46646 + b8759d1 commit d1d2eef

File tree

12 files changed

+524
-17
lines changed

12 files changed

+524
-17
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: v1
2+
name: aws-service-operator
3+
version: 0.0.1
4+
description: The AWS Service Operator allows you to manage AWS resources using Kubernetes Custom Resource Definitions.
5+
keywords:
6+
- AWS
7+
home: https://github.com/awslabs/aws-service-operator
8+
sources:
9+
- https://github.com/awslabs/aws-service-operator
10+
maintainers:
11+
- name: christopherhein
12+
13+
- name: acaire
14+
15+
engine: gotpl
16+
appVersion: v0.0.1-alpha2
17+
tillerVersion: ">=2.8.0"

charts/aws-service-operator/README.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# AWS Service Operator
2+
3+
This is the Helm chart for the [AWS Service Operator](https://github.com/awslabs/aws-service-operator)
4+
5+
## Prerequisites
6+
7+
- Kubernetes 1.9+
8+
9+
## Installing the chart
10+
Create AWS resources with Kubernetes
11+
The chart can be installed by running:
12+
13+
```bash
14+
$ helm repo add incubator http://storage.googleapis.com/kubernetes-charts-incubator
15+
$ helm install incubator/aws-service-operator
16+
```
17+
18+
## Configuration
19+
20+
The following table lists the configurable parameters of the aws-service-operator chart and their default values.
21+
22+
| Parameter | Description | Default |
23+
| ------------------------- | -------------------------------------- | -------------------------------------------------- |
24+
| `image.repository` | Container image repository | `awsserviceoperator/aws-service-operator` |
25+
| `image.tag` | Container image tag | `v0.0.1-alpha2` |
26+
| `image.pullPolicy` | Container pull policy | `IfNotPresent` |
27+
| `operator.accountId` | AWS Account ID to operator on | `""` |
28+
| `operator.bucket` | Base bucket to store resources in | `aws-operator` |
29+
| `operator.clusterName` | Used to label generated CF templates | `aws-operator` |
30+
| `operator.config` | Config file | `$HOME/.aws-operator.yaml` |
31+
| `operator.kubeconfig` | Path to local kubeconfig file | `""` |
32+
| `operator.logfile` | Log file | `""` |
33+
| `operator.loglevel` | Log level | `Info` |
34+
| `operator.region` | AWS Region for created resources | `us-west-2` |
35+
| `operator.resources` | Comma Delimited list of CRDS to deploy | `s3bucket,dynamodb` |
36+
| `affinity` | affinity settings for pod assignment | `{}` |
37+
| `extraArgs` | Optional CLI argument | `[]` |
38+
| `extraEnv` | Optional environment variables | `[]` |
39+
| `extraVolumes` | Custom Volumes | `[]` |
40+
| `extraVolumeMounts` | Custom VolumeMounts | `[]` |
41+
| `nodeSelector` | Node labels for pod assignment | `{}` |
42+
| `podAnnotations` | Annotations to attach to pod | `{}` |
43+
| `rbac.create` | Create RBAC roles | `true` |
44+
| `rbac.serviceAccountName` | Existing ServiceAccount to use | `default` |
45+
| `replicas` | Deployment replicas | `1` |
46+
| `resources` | container resource requests and limits | `{}` |
47+
| `tolerations` | Toleration labels for pod assignment | `[]` |
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
Thank you for installing the {{ .Chart.Name }} chart.
2+
3+
For more information on configuring {{ .Chart.Name }}, refer to {{ .Chart.Home }}
4+
5+
Your release is named {{ .Release.Name }}.
6+
7+
To learn more about the release, try:
8+
9+
$ helm status {{ .Release.Name }}
10+
$ helm get {{ .Release.Name }}
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
{{/*
2+
Helm standard labels.
3+
*/}}
4+
{{- define "aws-service-operator.helmStandardLabels" -}}
5+
app.kubernetes.io/name: {{ include "aws-service-operator.name" . }}
6+
helm.sh/chart: {{ include "aws-service-operator.chart" . }}
7+
app.kubernetes.io/managed-by: {{ .Release.Service }}
8+
app.kubernetes.io/instance: {{ .Release.Name }}
9+
app.kubernetes.io/version: {{ .Chart.AppVersion }}
10+
{{- end -}}
11+
12+
{{/*
13+
Helm pod labels.
14+
*/}}
15+
{{- define "aws-service-operator.helmPodLabels" -}}
16+
app.kubernetes.io/name: {{ include "aws-service-operator.name" . }}
17+
app.kubernetes.io/instance: {{ .Release.Name }}
18+
{{- end -}}
19+
20+
{{/*
21+
Create chart name and version as used by the chart label.
22+
*/}}
23+
{{- define "aws-service-operator.chart" -}}
24+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
25+
{{- end -}}
26+
27+
{{/*
28+
Expand the name of the chart.
29+
*/}}
30+
{{- define "aws-service-operator.name" -}}
31+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
32+
{{- end -}}
33+
34+
{{/*
35+
Create a default fully qualified app name.
36+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
37+
If release name contains chart name it will be used as a full name.
38+
*/}}
39+
{{- define "aws-service-operator.fullname" -}}
40+
{{- if .Values.fullnameOverride -}}
41+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
42+
{{- else -}}
43+
{{- $name := default .Chart.Name .Values.nameOverride -}}
44+
{{- if contains $name .Release.Name -}}
45+
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
46+
{{- else -}}
47+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
48+
{{- end -}}
49+
{{- end -}}
50+
{{- end -}}
51+
52+
{{/*
53+
Create the name of the service account to use.
54+
*/}}
55+
{{- define "aws-service-operator.serviceAccountName" -}}
56+
{{- if .Values.rbac.create -}}
57+
{{ default (include "aws-service-operator.fullname" .) .Values.rbac.serviceAccountName }}
58+
{{- else -}}
59+
{{ default "default" .Values.rbac.serviceAccountName }}
60+
{{- end -}}
61+
{{- end -}}
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
{{- if .Values.rbac.create -}}
2+
apiVersion: rbac.authorization.k8s.io/v1beta1
3+
kind: ClusterRole
4+
metadata:
5+
name: {{ template "aws-service-operator.fullname" . }}
6+
labels:
7+
{{ include "aws-service-operator.helmStandardLabels" . | indent 4 }}
8+
rules:
9+
- apiGroups:
10+
- ""
11+
resources:
12+
- secrets
13+
- pods
14+
- configmaps
15+
- services
16+
verbs:
17+
- get
18+
- list
19+
- watch
20+
- create
21+
- delete
22+
- update
23+
- apiGroups:
24+
- extensions
25+
resources:
26+
- thirdpartyresources
27+
verbs:
28+
- get
29+
- list
30+
- watch
31+
- create
32+
- delete
33+
- update
34+
- apiGroups:
35+
- apiextensions.k8s.io
36+
resources:
37+
- customresourcedefinitions
38+
verbs:
39+
- get
40+
- list
41+
- watch
42+
- create
43+
- delete
44+
- apiGroups:
45+
- service-operator.aws
46+
resources:
47+
- "*"
48+
verbs:
49+
- "*"
50+
{{- end -}}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{{- if .Values.rbac.create }}
2+
kind: ClusterRoleBinding
3+
apiVersion: rbac.authorization.k8s.io/v1
4+
metadata:
5+
name: {{ template "aws-service-operator.fullname" . }}
6+
labels:
7+
{{ include "aws-service-operator.helmStandardLabels" . | indent 4 }}
8+
roleRef:
9+
name: {{ template "aws-service-operator.fullname" . }}
10+
apiGroup: rbac.authorization.k8s.io
11+
kind: ClusterRole
12+
subjects:
13+
- name: {{ template "aws-service-operator.fullname" . }}
14+
kind: ServiceAccount
15+
namespace: {{ .Release.Namespace }}
16+
{{- end }}
Lines changed: 129 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
apiVersion: v1
2+
kind: List
3+
items:
4+
- apiVersion: apiextensions.k8s.io/v1beta1
5+
kind: CustomResourceDefinition
6+
metadata:
7+
name: cloudformationtemplates.service-operator.aws
8+
spec:
9+
group: service-operator.aws
10+
names:
11+
kind: CloudFormationTemplate
12+
listKind: CloudFormationTemplateList
13+
plural: cloudformationtemplates
14+
shortNames:
15+
- cft
16+
- cfts
17+
- cfn
18+
- cfns
19+
- cloudformation
20+
singular: cloudformationtemplates
21+
scope: Namespaced
22+
version: v1alpha1
23+
24+
- apiVersion: apiextensions.k8s.io/v1beta1
25+
kind: CustomResourceDefinition
26+
metadata:
27+
name: dynamodbs.service-operator.aws
28+
spec:
29+
group: service-operator.aws
30+
names:
31+
kind: DynamoDB
32+
listKind: DynamoDBList
33+
plural: dynamodbs
34+
shortNames:
35+
- ddb
36+
- ddbs
37+
- dynamo
38+
- dynamotable
39+
- dynamotables
40+
singular: dynamodbs
41+
scope: Namespaced
42+
version: v1alpha1
43+
44+
- apiVersion: apiextensions.k8s.io/v1beta1
45+
kind: CustomResourceDefinition
46+
metadata:
47+
name: ecrrepositories.service-operator.aws
48+
spec:
49+
group: service-operator.aws
50+
names:
51+
kind: ECRRepository
52+
listKind: ECRRepositoryList
53+
plural: ecrrepositories
54+
shortNames:
55+
- ecr
56+
- repository
57+
singular: ecrrepositories
58+
scope: Namespaced
59+
version: v1alpha1
60+
61+
- apiVersion: apiextensions.k8s.io/v1beta1
62+
kind: CustomResourceDefinition
63+
metadata:
64+
name: s3buckets.service-operator.aws
65+
spec:
66+
group: service-operator.aws
67+
names:
68+
kind: S3Bucket
69+
listKind: S3BucketList
70+
plural: s3buckets
71+
shortNames:
72+
- s3
73+
- bucket
74+
- buckets
75+
singular: s3buckets
76+
scope: Namespaced
77+
version: v1alpha1
78+
79+
- apiVersion: apiextensions.k8s.io/v1beta1
80+
kind: CustomResourceDefinition
81+
metadata:
82+
name: snssubscriptions.service-operator.aws
83+
spec:
84+
group: service-operator.aws
85+
names:
86+
kind: SNSSubscription
87+
listKind: SNSSubscriptionList
88+
plural: snssubscriptions
89+
shortNames:
90+
- subscription
91+
singular: snssubscriptions
92+
scope: Namespaced
93+
version: v1alpha1
94+
95+
- apiVersion: apiextensions.k8s.io/v1beta1
96+
kind: CustomResourceDefinition
97+
metadata:
98+
name: snstopics.service-operator.aws
99+
spec:
100+
group: service-operator.aws
101+
names:
102+
kind: SNSTopic
103+
listKind: SNSTopicList
104+
plural: snstopics
105+
shortNames:
106+
- sns
107+
- topic
108+
- topics
109+
singular: snstopics
110+
scope: Namespaced
111+
version: v1alpha1
112+
113+
- apiVersion: apiextensions.k8s.io/v1beta1
114+
kind: CustomResourceDefinition
115+
metadata:
116+
name: sqsqueues.service-operator.aws
117+
spec:
118+
group: service-operator.aws
119+
names:
120+
kind: SQSQueue
121+
listKind: SQSQueueList
122+
plural: sqsqueues
123+
shortNames:
124+
- sqs
125+
- queue
126+
- queues
127+
singular: sqsqueues
128+
scope: Namespaced
129+
version: v1alpha1

0 commit comments

Comments
 (0)