migrate wyoming to kubernetes
This commit is contained in:
@@ -1,49 +0,0 @@
|
|||||||
# currently hosted on chimera k3s cluster
|
|
||||||
# Add nodeSelector to schedule the pod on specific nodes
|
|
||||||
# Example: only schedule on nodes labeled with kubernetes.io/hostname=chimera
|
|
||||||
# Adjust the key/value as needed for your cluster
|
|
||||||
|
|
||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
namespace: casa-services
|
|
||||||
name: wyoming-whisper
|
|
||||||
labels:
|
|
||||||
app: wyoming-whisper
|
|
||||||
spec:
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: wyoming-whisper
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: wyoming-whisper
|
|
||||||
spec:
|
|
||||||
nodeSelector:
|
|
||||||
kubernetes.io/hostname: chimera-flashgordon
|
|
||||||
tolerations:
|
|
||||||
- key: "dedicated"
|
|
||||||
value: "reserved"
|
|
||||||
effect: "NoSchedule"
|
|
||||||
|
|
||||||
containers:
|
|
||||||
- name: wyoming-whisper
|
|
||||||
image: rhasspy/wyoming-whisper
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /data
|
|
||||||
name: data
|
|
||||||
args:
|
|
||||||
- --model
|
|
||||||
- small-int8
|
|
||||||
- --language
|
|
||||||
- pt
|
|
||||||
- --beam-size
|
|
||||||
- "4"
|
|
||||||
- --debug
|
|
||||||
ports:
|
|
||||||
- containerPort: 10300
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: wyoming-whisper
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: wyoming-whisper
|
|
||||||
namespace: casa-services
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteOnce
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 8Gi
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: wyoming-whisper
|
|
||||||
namespace: casa-services
|
|
||||||
labels:
|
|
||||||
app: wyoming-whisper
|
|
||||||
spec:
|
|
||||||
type: LoadBalancer
|
|
||||||
loadBalancerIP: 192.168.14.201 # using metallb
|
|
||||||
selector:
|
|
||||||
app: wyoming-whisper
|
|
||||||
ports:
|
|
||||||
- port: 10300
|
|
||||||
targetPort: 10300
|
|
||||||
149
services/wyoming/deploy/wyoming-deploy.yaml
Normal file
149
services/wyoming/deploy/wyoming-deploy.yaml
Normal file
@@ -0,0 +1,149 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: wyoming
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: wyoming-whisper
|
||||||
|
namespace: wyoming
|
||||||
|
labels:
|
||||||
|
app: wyoming-piper
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app: wyoming-piper
|
||||||
|
ports:
|
||||||
|
- name: tcp-piper
|
||||||
|
protocol: TCP
|
||||||
|
port: 10300
|
||||||
|
targetPort: 10300
|
||||||
|
type: ClusterIP
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
namespace: wyoming
|
||||||
|
name: wyoming-whisper
|
||||||
|
labels:
|
||||||
|
app: wyoming-whisper
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: wyoming-whisper
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: wyoming-whisper
|
||||||
|
spec:
|
||||||
|
nodeSelector:
|
||||||
|
role: worker-node
|
||||||
|
containers:
|
||||||
|
- name: wyoming-whisper
|
||||||
|
image: rhasspy/wyoming-whisper
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /data
|
||||||
|
name: data
|
||||||
|
args:
|
||||||
|
- --model
|
||||||
|
- small-int8
|
||||||
|
- --language
|
||||||
|
- pt
|
||||||
|
- --beam-size
|
||||||
|
- "4"
|
||||||
|
- --debug
|
||||||
|
ports:
|
||||||
|
- containerPort: 10300
|
||||||
|
volumes:
|
||||||
|
- name: data
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: wyoming-whisper
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: wyoming-whisper
|
||||||
|
namespace: wyoming
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 8Gi
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: wyoming-piper
|
||||||
|
namespace: wyoming
|
||||||
|
labels:
|
||||||
|
app: wyoming-piper
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app: wyoming-piper
|
||||||
|
ports:
|
||||||
|
- name: tcp-piper
|
||||||
|
protocol: TCP
|
||||||
|
port: 10200
|
||||||
|
targetPort: 10200
|
||||||
|
type: ClusterIP
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
namespace: wyoming
|
||||||
|
name: wyoming-piper
|
||||||
|
labels:
|
||||||
|
app: wyoming-piper
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: wyoming-piper
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: wyoming-piper
|
||||||
|
spec:
|
||||||
|
nodeSelector:
|
||||||
|
role: worker-node
|
||||||
|
containers:
|
||||||
|
- name: wyoming-piper
|
||||||
|
image: rhasspy/wyoming-piper
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /data
|
||||||
|
name: data
|
||||||
|
args:
|
||||||
|
- --voice
|
||||||
|
- en-gb-southern_english_female-low
|
||||||
|
ports:
|
||||||
|
- containerPort: 10200
|
||||||
|
volumes:
|
||||||
|
- name: data
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: wyoming-piper
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: wyoming-piper
|
||||||
|
namespace: wyoming
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 2Gi
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
services:
|
|
||||||
whisper:
|
|
||||||
image: linuxserver/faster-whisper # this whisper is not really used.. using an pof on chimera, for better performance
|
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
|
||||||
- whisper_data:/data
|
|
||||||
ports:
|
|
||||||
- 10300:10300
|
|
||||||
environment:
|
|
||||||
- TZ=Europe/Lisbon
|
|
||||||
- WHISPER_MODEL=small-int8
|
|
||||||
- WHISPER_LANG=pt
|
|
||||||
piper:
|
|
||||||
image: rhasspy/wyoming-piper
|
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
|
||||||
- piper_data:/data
|
|
||||||
ports:
|
|
||||||
- 10200:10200
|
|
||||||
environment:
|
|
||||||
- TZ=Europe/Lisbon
|
|
||||||
command: [ "--voice", "en-gb-southern_english_female-low" ]
|
|
||||||
volumes:
|
|
||||||
whisper_data:
|
|
||||||
piper_data:
|
|
||||||
Reference in New Issue
Block a user