1
0
Fork 0
home-stack-kustomize/kustomize/bases/sillytavern/sillytavern-deployment.yaml

92 lines
2.1 KiB
YAML
Raw Normal View History

2024-07-06 16:37:26 +00:00
apiVersion: apps/v1
kind: Deployment
metadata:
name: server
spec:
strategy:
type: Recreate
selector:
matchLabels:
app.kubernetes.io/component: server
template:
metadata:
labels:
app.kubernetes.io/component: server
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
# Image only supports amd64
- key: kubernetes.io/arch
operator: In
values:
- amd64
containers:
- name: sillytavern
image: ghcr.io/sillytavern/sillytavern:latest
resources:
requests:
memory: 256Mi
2024-07-06 16:37:26 +00:00
cpu: 200m
limits:
memory: 256Mi
2024-07-06 16:37:26 +00:00
cpu: 200m
ports:
- containerPort: 8000
name: http
volumeMounts:
# - name: sillytavern-plugins
# mountPath: /home/node/app/plugins
2024-07-06 16:37:26 +00:00
- name: sillytavern-config
mountPath: /home/node/app/config/config.yaml
subPath: config.yaml
- name: sillytavern-data
mountPath: /home/node/app/data
2024-07-06 16:37:26 +00:00
volumes:
# - name: sillytavern-plugins
# persistentVolumeClaim:
# claimName: server-plugins
2024-07-06 16:37:26 +00:00
- name: sillytavern-config
configMap:
name: server-config
- name: sillytavern-data
2024-07-06 16:37:26 +00:00
persistentVolumeClaim:
claimName: server-data
2024-07-06 16:37:26 +00:00
---
# apiVersion: v1
# kind: PersistentVolumeClaim
# metadata:
# name: server-plugins
# spec:
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 1Gi
2024-07-06 16:37:26 +00:00
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: server-data
2024-07-06 16:37:26 +00:00
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
---
apiVersion: v1
kind: Service
metadata:
name: server
labels:
app.kubernetes.io/component: server
spec:
selector:
app.kubernetes.io/component: server
ports:
- name: http
port: 8000
targetPort: http