This commit is contained in:
Nathan Rashleigh committed 2025-04-12 21:11:40 +10:00
1 parent 2b38528445
commit 8b0ef37ffa
5 files changed
+94 -129

No files matched your search

+19 -24
View File
@@ -1,26 +1,13 @@
# -----------------------------------------------------------------------
# VOLUMES
# -----------------------------------------------------------------------
---
apiVersion: v1
kind: PersistentVolume
kind: Namespace
metadata:
name: crates-postgres-pv
spec:
storageClassName: ""
capacity:
storage: 1Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
claimRef:
namespace: default
name: crates-postgres-pvc
hostPath:
path: "/var/lib/rancher/k3s/storage/crates-postgres-pv"
type: DirectoryOrCreate
name: crates
# -----------------------------------------------------------------------
# VOLUMES
# -----------------------------------------------------------------------
---
@@ -28,13 +15,14 @@ kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: crates-postgres-pvc
namespace: crates
spec:
volumeName: crates-postgres-pv
storageClassName: zfs-fast
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storage: 2Gi
---
@@ -46,6 +34,7 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: crates-postgres
namespace: crates
spec:
replicas: 1
selector:
@@ -91,6 +80,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: crates
name: crates-api
spec:
replicas: 1
@@ -104,7 +94,7 @@ spec:
spec:
containers:
- name: crates-api
image: registry.strix.systems/crates-api
image: registry.ntwl.xyz/crates-api
imagePullPolicy: Always
ports:
- containerPort: 80
@@ -136,6 +126,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: crates
name: crates-migrate
spec:
replicas: 1
@@ -149,7 +140,7 @@ spec:
spec:
containers:
- name: crates-migrate
image: registry.strix.systems/crates-api
image: registry.ntwl.xyz/crates-api
imagePullPolicy: IfNotPresent
command: ["npx"]
args: ["prisma", "migrate", "deploy"]
@@ -165,6 +156,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: crates
name: crates-client
spec:
replicas: 1
@@ -178,7 +170,7 @@ spec:
spec:
containers:
- name: crates-client
image: registry.strix.systems/crates-client
image: registry.ntwl.xyz/crates-client
imagePullPolicy: Always
ports:
- containerPort: 8080
@@ -192,6 +184,7 @@ spec:
apiVersion: v1
kind: Service
metadata:
namespace: crates
name: crates-api
spec:
selector:
@@ -204,6 +197,7 @@ spec:
apiVersion: v1
kind: Service
metadata:
namespace: crates
name: crates-postgres
spec:
selector:
@@ -216,6 +210,7 @@ spec:
apiVersion: v1
kind: Service
metadata:
namespace: crates
name: crates-client
spec:
selector: