-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add fio-standalone Helm chart v0.1.0
- Loading branch information
Showing
10 changed files
with
227 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# 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 | ||
*.orig | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj | ||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
apiVersion: v2 | ||
name: fio-standalone | ||
description: Benchmark a single Kubernetes StorageClass | ||
type: application | ||
version: 0.1.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
Benchmark against StorageClass {{ .Values.pvc.storageClassName }} is running! | ||
|
||
Check the status of the Job to see when the benchmark is complete: | ||
kubectl get jobs -n {{ .Release.Namespace }} | ||
|
||
View logs of the completed benchmark: | ||
kubectl logs -n {{ .Release.Namespace }} job/{{ include "fio-standalone.fullname" . }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{{/* | ||
Expand the name of the chart. | ||
*/}} | ||
{{- define "fio-standalone.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). | ||
If release name contains chart name it will be used as a full name. | ||
*/}} | ||
{{- define "fio-standalone.fullname" -}} | ||
{{- if .Values.fullnameOverride }} | ||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} | ||
{{- else }} | ||
{{- $name := default .Chart.Name .Values.nameOverride }} | ||
{{- if contains $name .Release.Name }} | ||
{{- .Release.Name | trunc 63 | trimSuffix "-" }} | ||
{{- else }} | ||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create chart name and version as used by the chart label. | ||
*/}} | ||
{{- define "fio-standalone.chart" -}} | ||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} | ||
{{- end }} | ||
|
||
{{/* | ||
Common labels | ||
*/}} | ||
{{- define "fio-standalone.labels" -}} | ||
helm.sh/chart: {{ include "fio-standalone.chart" . }} | ||
{{ include "fio-standalone.selectorLabels" . }} | ||
{{- if .Chart.AppVersion }} | ||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} | ||
{{- end }} | ||
app.kubernetes.io/managed-by: {{ .Release.Service }} | ||
{{- end }} | ||
|
||
{{/* | ||
Selector labels | ||
*/}} | ||
{{- define "fio-standalone.selectorLabels" -}} | ||
app.kubernetes.io/name: {{ include "fio-standalone.name" . }} | ||
app.kubernetes.io/instance: {{ .Release.Name }} | ||
{{- end }} | ||
|
||
{{/* | ||
Create the name of the service account to use | ||
*/}} | ||
{{- define "fio-standalone.serviceAccountName" -}} | ||
{{- if .Values.serviceAccount.create }} | ||
{{- default (include "fio-standalone.fullname" .) .Values.serviceAccount.name }} | ||
{{- else }} | ||
{{- default "default" .Values.serviceAccount.name }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
apiVersion: batch/v1 | ||
kind: Job | ||
metadata: | ||
name: {{ include "fio-standalone.fullname" . }} | ||
spec: | ||
template: | ||
metadata: | ||
labels: | ||
benchmark: fio | ||
spec: | ||
containers: | ||
- name: benchmark | ||
image: {{ .Values.benchmark.image.repository }}:{{ .Values.benchmark.image.tag }} | ||
imagePullPolicy: {{ .Values.benchmark.image.pullPolicy }} | ||
env: | ||
{{- if .Values.benchmark.quickMode }} | ||
- name: QUICK_MODE # for debugging | ||
value: "1" | ||
{{- end }} | ||
- name: FILE_NAME | ||
value: "/volume/test" | ||
- name: SIZE | ||
value: "2G" # must be smaller or match the PVC size | ||
volumeMounts: | ||
- name: vol | ||
mountPath: /volume/ | ||
imagePullSecrets: {{ .Values.benchmark.imagePullSecrets }} | ||
restartPolicy: Never | ||
volumes: | ||
- name: vol | ||
persistentVolumeClaim: | ||
claimName: {{ include "fio-standalone.fullname" . }} | ||
backoffLimit: 0 |
14 changes: 14 additions & 0 deletions
14
helm/charts/fio-standalone/0.1.0/templates/persistent-volume-claim.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
kind: PersistentVolumeClaim | ||
apiVersion: v1 | ||
metadata: | ||
name: {{ include "fio-standalone.fullname" . }} | ||
spec: | ||
volumeMode: {{ .Values.pvc.volumeMode | quote }} | ||
{{- if .Values.pvc.storageClassName }} | ||
storageClassName: {{ .Values.pvc.storageClassName | quote }} | ||
{{- end }} | ||
accessModes: | ||
- ReadWriteOnce | ||
resources: | ||
requests: | ||
storage: {{ .Values.pvc.size | quote }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
pvc: | ||
# specify storage class to test; | ||
# "" will use the default StorageClass for the cluster | ||
storageClassName: "" | ||
# size of PVC; must be larger than benchmark.size | ||
# NOTE the format: 3Gi, 5Gi, etc. | ||
size: "3Gi" | ||
# mode for PVC - "Filesystem" or "Block" | ||
volumeMode: "Filesystem" | ||
|
||
benchmark: | ||
# size of benchmark tests; must be smaller than pvc.size | ||
# NOTE the format: 2G, 4G, etc. | ||
size: "2G" | ||
image: | ||
repository: "yasker/benchmark" | ||
pullPolicy: "IfNotPresent" | ||
tag: "latest" | ||
imagePullSecrets: [] | ||
quickMode: false | ||
|
||
nameOverride: "" | ||
fullnameOverride: "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
apiVersion: v1 | ||
entries: | ||
fio-standalone: | ||
- apiVersion: v2 | ||
created: "2021-07-23T02:12:49.792704-04:00" | ||
description: Benchmark a single Kubernetes StorageClass | ||
digest: f847c4e45bb4187810313a48e0ed4884eb1130c65cda9c165725ddedd25673fc | ||
name: fio-standalone | ||
type: application | ||
urls: | ||
- assets/fio-standalone-0.1.0.tgz | ||
version: 0.1.0 | ||
generated: "2021-07-23T02:12:49.791916-04:00" |