Files
kubernetes/websites/darkchestofwonders.us/server.yaml
Dustin C. Hatch ced5a7b4a1 websites: Host darkchestofwonders.us in k8s
The *darkchestofwonders.us* website is a legacy Python/mod_wsgi
application.  It was down for a while after updating the main web server
to Fedora 38.  Although we don't upload as many screenshots anymore, we
do still enjoy looking at the old ones.  Until I get a chance to either
update the site to use a more modern deplyoment mechansim, or move the
screenshots to some other photo hosting system, the easiest way to keep
it online is to run it in a container.
2024-01-04 08:56:12 -06:00

95 lines
2.4 KiB
YAML

---
apiVersion: v1
kind: Service
metadata:
labels:
app.kubernetes.io/component: darkchestofwonders.us
app.kubernetes.io/name: darkchestofwonders.us
app.kubernetes.io/part-of: darkchestofwonders.us
name: darkchestofwonders
spec:
ports:
- port: 8204
name: http
selector:
app.kubernetes.io/component: darkchestofwonders.us
app.kubernetes.io/name: darkchestofwonders.us
---
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app.kubernetes.io/component: darkchestofwonders.us
app.kubernetes.io/name: darkchestofwonders.us
app.kubernetes.io/part-of: darkchestofwonders.us
name: darkchestofwonders
spec:
selector:
matchLabels:
app.kubernetes.io/component: darkchestofwonders.us
app.kubernetes.io/name: darkchestofwonders.us
template:
metadata:
labels:
app.kubernetes.io/component: darkchestofwonders.us
app.kubernetes.io/name: darkchestofwonders.us
app.kubernetes.io/part-of: darkchestofwonders.us
spec:
containers:
- name: darkchestofwonders
image: git.pyrocufflink.net/packages/darkchestofwonders:5
envFrom:
- configMapRef:
name: darkchestofwonders.us
optional: true
ports:
- containerPort: 8204
name: http
readinessProbe: &probe
httpGet:
port: 8204
path: /
failureThreshold: 3
periodSeconds: 60
successThreshold: 1
timeoutSeconds: 1
startupProbe:
<<: *probe
failureThreshold: 30
periodSeconds: 1
initialDelaySeconds: 1
securityContext:
readOnlyRootFilesystem: true
volumeMounts:
- mountPath: /data
name: data
subPath: data
- mountPath: /data/screenshots
name: data
subPath: data/screenshots
- mountPath: /data/thumbnails
name: data
subPath: data/thumbnails
- mountPath: /run
name: tmp
subPath: run
- mountPath: /run/httpd
name: tmp
subPath: run/httpd
- mountPath: /tmp
name: tmp
subPath: tmp
securityContext:
fsGroup: 48
runAsGroup: 48
runAsNonRoot: true
runAsUser: 48
volumes:
- name: data
persistentVolumeClaim:
claimName: darkchestofwonders.us
- name: tmp
emptyDir:
medium: Memory