Skip to content

Commit 9e958e2

Browse files
chore: change chart for new application
1 parent 16c4f7a commit 9e958e2

File tree

8 files changed

+294
-0
lines changed

8 files changed

+294
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*.orig
18+
*~
19+
# Various IDEs
20+
.project
21+
.idea/
22+
*.tmproj
23+
.vscode/
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
apiVersion: v2
2+
name: json-api-proxy
3+
description: A Helm chart for the JSON API Proxies
4+
5+
# A chart can be either an 'application' or a 'library' chart.
6+
#
7+
# Application charts are a collection of templates that can be packaged into versioned archives
8+
# to be deployed.
9+
#
10+
# Library charts provide useful utilities or functions for the chart developer. They're included as
11+
# a dependency of application charts to inject those utilities and functions into the rendering
12+
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
13+
type: application
14+
15+
# This is the chart version. This version number should be incremented each time you make changes
16+
# to the chart and its templates, including the app version.
17+
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18+
version: 0.0.1
19+
20+
# This is the version number of the application being deployed. This version number should be
21+
# incremented each time you make changes to the application. Versions are not expected to
22+
# follow Semantic Versioning. They should reflect the version the application is using.
23+
appVersion: 0.0.1
24+
25+
keywords:
26+
- proxy
27+
- grafana
28+
- JSON
29+
- API
30+
31+
home: https://github.com/devopsmakers/grafana-json-api-proxies/tree/main/helm-charts/json-api-proxy
32+
33+
sources:
34+
- https://github.com/devopsmakers/grafana-json-api-proxies/
35+
36+
maintainers:
37+
- name: Tim Birkett
38+
39+
annotations:
40+
artifacthub.io/changes: |
41+
- version 0.0.1
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# json-api-proxy
2+
3+
![Version: 0.0.1](https://img.shields.io/badge/Version-0.0.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.0.1](https://img.shields.io/badge/AppVersion-0.0.1-informational?style=flat-square)
4+
5+
A Helm chart for the JSON API Proxies
6+
7+
**Homepage:** <https://github.com/devopsmakers/grafana-json-api-proxies/tree/main/helm-charts/json-api-proxy>
8+
9+
## Installation
10+
```
11+
helm repo add grafana-json-apis-proxies https://devopsmakers.github.io/grafana-json-apis-proxies
12+
helm install json-api-proxy grafana-json-api-proxies/json-api-proxy
13+
```
14+
15+
## Maintainers
16+
17+
| Name | Email | Url |
18+
| ---- | ------ | --- |
19+
| Tim Birkett | | |
20+
21+
## Source Code
22+
23+
* <https://github.com/devopsmakers/grafana-json-api-proxies/>
24+
25+
## Values
26+
27+
| Key | Type | Default | Description |
28+
|-----|------|---------|-------------|
29+
| affinity | object | `{}` | |
30+
| env | list | `[]` | |
31+
| fullnameOverride | string | `"ical-proxy"` | |
32+
| image.repository | string | `"ghcr.io/devopsmakers/ical-proxy"` | |
33+
| image.tag | string | `""` | |
34+
| imagePullSecrets | list | `[]` | |
35+
| nameOverride | string | `"ical-proxy"` | |
36+
| nodeSelector | object | `{}` | |
37+
| replicaCount | int | `1` | |
38+
| resources | object | `{}` | |
39+
| tolerations | list | `[]` | |
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{{ template "chart.header" . }}
2+
{{ template "chart.deprecationWarning" . }}
3+
4+
{{ template "chart.badgesSection" . }}
5+
6+
{{ template "chart.description" . }}
7+
8+
{{ template "chart.homepageLine" . }}
9+
10+
## Installation
11+
```
12+
helm repo add grafana-json-apis-proxies https://devopsmakers.github.io/grafana-json-apis-proxies
13+
helm install {{ template "chart.name" . }} grafana-json-api-proxies/{{ template "chart.name" . }}
14+
```
15+
16+
{{ template "chart.maintainersSection" . }}
17+
18+
{{ template "chart.sourcesSection" . }}
19+
20+
{{ template "chart.requirementsSection" . }}
21+
22+
{{ template "chart.valuesSection" . }}
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
{{/*
2+
Expand the name of the chart.
3+
*/}}
4+
{{- define "json-api-proxy.name" -}}
5+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
6+
{{- end }}
7+
8+
{{/*
9+
Create a default fully qualified app name.
10+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
11+
If release name contains chart name it will be used as a full name.
12+
*/}}
13+
{{- define "json-api-proxy.fullname" -}}
14+
{{- if .Values.fullnameOverride }}
15+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
16+
{{- else }}
17+
{{- $name := default .Chart.Name .Values.nameOverride }}
18+
{{- if contains $name .Release.Name }}
19+
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
20+
{{- else }}
21+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
22+
{{- end }}
23+
{{- end }}
24+
{{- end }}
25+
26+
{{/*
27+
Create chart name and version as used by the chart label.
28+
*/}}
29+
{{- define "json-api-proxy.chart" -}}
30+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
31+
{{- end }}
32+
33+
{{/*
34+
Common labels
35+
*/}}
36+
{{- define "json-api-proxy.labels" -}}
37+
helm.sh/chart: {{ include "json-api-proxy.chart" . }}
38+
{{ include "json-api-proxy.selectorLabels" . }}
39+
{{- if .Chart.AppVersion }}
40+
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
41+
{{- end }}
42+
app.kubernetes.io/managed-by: {{ .Release.Service }}
43+
{{- end }}
44+
45+
{{/*
46+
Selector labels
47+
*/}}
48+
{{- define "json-api-proxy.selectorLabels" -}}
49+
app.kubernetes.io/name: {{ include "json-api-proxy.name" . }}
50+
app.kubernetes.io/instance: {{ .Release.Name }}
51+
{{- end }}
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
apiVersion: apps/v1
2+
kind: Deployment
3+
metadata:
4+
name: {{ include "json-api-proxy.fullname" . }}
5+
labels:
6+
{{- include "json-api-proxy.labels" . | nindent 4 }}
7+
spec:
8+
replicas: {{ .Values.replicaCount }}
9+
selector:
10+
matchLabels:
11+
{{- include "json-api-proxy.selectorLabels" . | nindent 6 }}
12+
template:
13+
metadata:
14+
labels:
15+
{{- include "json-api-proxy.selectorLabels" . | nindent 8 }}
16+
spec:
17+
{{- with .Values.imagePullSecrets }}
18+
imagePullSecrets:
19+
{{- toYaml . | nindent 8 }}
20+
{{- end }}
21+
automountServiceAccountToken: false
22+
securityContext:
23+
{{- toYaml .Values.podSecurityContext | nindent 8 }}
24+
containers:
25+
- name: {{ .Chart.Name }}
26+
securityContext:
27+
allowPrivilegeEscalation: false
28+
readOnlyRootFilesystem: true
29+
runAsNonRoot: true
30+
runAsUser: 1337
31+
capabilities:
32+
drop:
33+
- ALL
34+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
35+
imagePullPolicy: Always
36+
ports:
37+
- name: http
38+
containerPort: 5000
39+
protocol: TCP
40+
livenessProbe:
41+
httpGet:
42+
path: /
43+
port: http
44+
periodSeconds: 10
45+
timeoutSeconds: 5
46+
readinessProbe:
47+
httpGet:
48+
path: /
49+
port: http
50+
periodSeconds: 10
51+
timeoutSeconds: 5
52+
resources:
53+
{{- toYaml .Values.resources | nindent 12 }}
54+
{{- with .Values.env }}
55+
env:
56+
{{- toYaml . | nindent 12 }}
57+
{{- end }}
58+
{{- with .Values.nodeSelector }}
59+
nodeSelector:
60+
{{- toYaml . | nindent 8 }}
61+
{{- end }}
62+
{{- with .Values.affinity }}
63+
affinity:
64+
{{- toYaml . | nindent 8 }}
65+
{{- end }}
66+
{{- with .Values.tolerations }}
67+
tolerations:
68+
{{- toYaml . | nindent 8 }}
69+
{{- end }}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
apiVersion: v1
2+
kind: Service
3+
metadata:
4+
name: {{ include "json-api-proxy.fullname" . }}
5+
spec:
6+
type: ClusterIP
7+
selector:
8+
{{- include "json-api-proxy.selectorLabels" . | nindent 4 }}
9+
ports:
10+
- name: http
11+
protocol: TCP
12+
port: 5000
13+
targetPort: 5000
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Default values for json-api-proxy
2+
# This is a YAML-formatted file.
3+
# Declare variables to be passed into your templates.
4+
5+
replicaCount: 1
6+
7+
image:
8+
repository: ghcr.io/devopsmakers/ical-proxy
9+
# Overrides the image tag whose default is the chart appVersion.
10+
tag: ""
11+
12+
imagePullSecrets: []
13+
nameOverride: "ical-proxy"
14+
fullnameOverride: "ical-proxy"
15+
16+
resources: {}
17+
# We usually recommend not to specify default resources and to leave this as a conscious
18+
# choice for the user. This also increases chances charts run on environments with little
19+
# resources, such as Minikube. If you do want to specify resources, uncomment the following
20+
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
21+
# limits:
22+
# cpu: 100m
23+
# memory: 128Mi
24+
# requests:
25+
# cpu: 100m
26+
# memory: 128Mi
27+
28+
nodeSelector: {}
29+
30+
tolerations: []
31+
32+
affinity: {}
33+
34+
env: []
35+
# - name: CACHE_TTL
36+
# value: "300"

0 commit comments

Comments
 (0)