add isolated live development deployments

This commit is contained in:
2026-07-21 20:58:12 +00:00
parent 12711bc3fa
commit 872529b3d9
16 changed files with 322 additions and 8 deletions

6
dev/helm/Chart.yaml Normal file
View File

@@ -0,0 +1,6 @@
apiVersion: v2
name: hello-dev
description: Live-edit development deployment for the hello application
type: application
version: 0.1.0
appVersion: "1.29"

View File

@@ -0,0 +1,46 @@
{{- $instance := required "instance is required" .Values.instance -}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Release.Name | quote }}
labels:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
app.kubernetes.io/instance: {{ $instance | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
template:
metadata:
labels:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
app.kubernetes.io/instance: {{ $instance | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
spec:
containers:
- name: nginx
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: 80
protocol: TCP
readinessProbe:
httpGet:
path: /
port: http
livenessProbe:
httpGet:
path: /
port: http
volumeMounts:
- name: source
mountPath: /usr/share/nginx/html
subPath: {{ required "sharedVolume.subPath is required" .Values.sharedVolume.subPath | quote }}
volumes:
- name: source
persistentVolumeClaim:
claimName: {{ .Values.sharedVolume.claimName | quote }}

View File

@@ -0,0 +1,23 @@
{{- $instance := required "instance is required" .Values.instance -}}
{{- $host := required "ingress.host is required" .Values.ingress.host -}}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ .Release.Name | quote }}
labels:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
app.kubernetes.io/instance: {{ $instance | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
spec:
ingressClassName: {{ .Values.ingress.className }}
rules:
- host: {{ $host | quote }}
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: {{ .Release.Name | quote }}
port:
number: {{ .Values.service.port }}

View File

@@ -0,0 +1,19 @@
{{- $instance := required "instance is required" .Values.instance -}}
apiVersion: v1
kind: Service
metadata:
name: {{ .Release.Name | quote }}
labels:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
app.kubernetes.io/instance: {{ $instance | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
spec:
type: ClusterIP
selector:
app.kubernetes.io/name: {{ .Chart.Name | quote }}
dev.mancave.link/instance: {{ $instance | quote }}
ports:
- name: http
port: {{ .Values.service.port }}
targetPort: http
protocol: TCP

17
dev/helm/values.yaml Normal file
View File

@@ -0,0 +1,17 @@
instance: ""
image:
repository: nginx
tag: 1.29-alpine
pullPolicy: IfNotPresent
sharedVolume:
claimName: control-vibes-control-data
subPath: ""
service:
port: 80
ingress:
className: nginx
host: ""