Skip to content

Instantly share code, notes, and snippets.

View Mishco's full-sized avatar
🎯
Focusing

Michal Slovík Mishco

🎯
Focusing
View GitHub Profile
helm/
first-image/
second-image/
third-image/
config/
data/
templates/
.helmignore
Chart.yaml
Charts.yaml
apiVersion: v2
name: <first-app>
description: A Helm chart for Kubernetes
type: application
version: 0.1.2
appVersion: 1.16.0
host: first-app.full-address.com
keyvault: dev-key-vault
apiVersion: spv.no/v1alpha1
kind: AzureKeyVaultSecret
metadata:
name: certificat-sync
namespace: namespace-first-app
spec:
vault:
name: {{ .Values.keyvault }} # value get from 'values.yaml'
object:
name: first-app
apiVersion: v1
kind: ConfigMap
metadata:
name: first-app-config
labels:
run: first-app
data:
"first-app-config.config": |-
{{ .Files.Get "config/first-app-config.config" | indent 4 }}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: first-app-ingress
namespace: namespace-first-app
annotations:
nginx.ingress.kubernetes.io/proxy-connect-timeout: "30000"
nginx.ingress.kubernetes.io/rewrite-target: /$1
spec:
rules:
apiVersion: apps/v1
kind: Deployment
metadata:
name: first-app
namespace: namespace-first-app
spec:
replicas: 1
selector:
matchLabels:
run: first-app
template:
metadata:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/config.yaml") . | sha256sum }}
labels:
run: first-app
spec:
containers:
- env:
- name: LICENSE
value: {{ .Values.LICENSE }}
image: dev.azurecr.io/first-app-application:latest
name: first-app
ports:
- containerPort: 3939 # Application port
protocol: TCP
resources: {}
volumeMounts:
- mountPath: "/data/"
name: data
- name: config-volume
mountPath: "/etc/config.config"
subPath: first-app-config.config
volumes:
- name: data
persistentVolumeClaim: