Add helm charts

This commit is contained in:
Alexandre Ferreira
2022-10-26 14:18:43 +00:00
parent fe5dca8f1c
commit c42e92595f
5 changed files with 142 additions and 0 deletions

26
chart/.helmignore Normal file
View File

@@ -0,0 +1,26 @@
# 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
.vscode/
# OWNERS file for Kubernetes
OWNERS
# helm-docs templates
*.gotmpl

30
chart/Chart.yaml Normal file
View File

@@ -0,0 +1,30 @@
apiVersion: v2
name: smarter-device-manager
description: smarter-device-manager chart for SMARTER edge devices
home: https://gitlab.com/smarter-project/smarter-device-manager/helm
version: 0.0.2
appVersion: v1.20.11
kubeVersion: ">=1.16.0-0"
keywords:
- kubernetes
- device
- hardware
sources:
- https://gitlab.com/smarter-project/smarter-device-manager
#dependencies:
# - name: smarter-common
# repository: https://gitlab.com/smarter-project/documentation
# version: 0.0.1
annotations:
artifacthub.io/changes: |
- Fix template
- Add annotations
artifacthub.io/license: Apache-2.0
artifacthub.io/maintainers: |
- name: Alexandre Ferreira
email: alexandref75@gmail.com
artifacthub.io/prerelease: "false"
artifacthub.io/signKey: |
fingerprint: 82AD709FEC4ECA4C84B093889BDC9DE410CFC23B
url: https://keybase.io/alexandref75/pgp_keys.asc

8
chart/README.md Normal file
View File

@@ -0,0 +1,8 @@
# smarter-device-manager
## TL;DR
```console
helm install smarter-device-manager chart
```

View File

@@ -0,0 +1,66 @@
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: {{ .Values.application.appName }}
namespace: {{ .Values.application.namespace }}
labels:
name: {{ .Values.application.appName }}
role: agent
spec:
selector:
matchLabels:
name: {{ .Values.application.appName }}
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
name: {{ .Values.application.appName }}
annotations:
node.kubernetes.io/bootstrap-checkpoint: "true"
spec:
nodeSelector:
smarter-device-manager : enabled
tolerations:
- key: "smarter.type"
operator: "Equal"
value: "edge"
effect: "NoSchedule"
priorityClassName: "system-node-critical"
hostname: {{ .Values.application.appName }}
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
containers:
- name: {{ .Values.application.appName }}
image: {{ .Values.image.repository }}:{{ default .Chart.AppVersion .Values.image.tag }}
imagePullPolicy: {{ .Values.pullPolicy }}
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop: ["ALL"]
resources:
limits:
cpu: 100m
memory: 15Mi
requests:
cpu: 10m
memory: 15Mi
volumeMounts:
- name: device-plugin
mountPath: /var/lib/kubelet/device-plugins
- name: dev-dir
mountPath: /dev
- name: sys-dir
mountPath: /sys
volumes:
- name: device-plugin
hostPath:
path: /var/lib/kubelet/device-plugins
- name: dev-dir
hostPath:
path: /dev
- name: sys-dir
hostPath:
path: /sys
terminationGracePeriodSeconds: 30

12
chart/values.yaml Normal file
View File

@@ -0,0 +1,12 @@
#
application:
namespace: smarter
appName: smarter-device-manager
image:
repository: registry.gitlab.com/arm-research/smarter/smarter-device-manager
#repository: registry.gitlab.com/smarter-project/smarter-device-manager
# @default -- chart.appVersion
tag: ""
pullPolicy: IfNotPresent