1
0
Fork 0

add openedai-speech for tts

This commit is contained in:
Massaki Archambault 2024-08-23 01:06:46 -04:00
parent 53b77ba489
commit edd3ec51ed
5 changed files with 115 additions and 4 deletions

View File

@ -31,7 +31,7 @@ spec:
image: ollama/ollama
env:
- name: OLLAMA_KEEP_ALIVE
value: 36h
value: 12h
# - name: HSA_OVERRIDE_GFX_VERSION
# value: 10.1.0
# - name: HSA_ENABLE_SDMA

View File

@ -0,0 +1,11 @@
resources:
- openedai-speech-deployment.yaml
namePrefix: openedai-speech-
commonLabels:
app.kubernetes.io/name: openedai-speech
# configMapGenerator:
# - name: server-config
# files: []

View File

@ -0,0 +1,93 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: server
labels:
app.kubernetes.io/component: server
spec:
replicas: 1
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: openedai-speech
image: ghcr.io/matatonic/openedai-speech
ports:
- name: http
containerPort: 8000
resources:
requests:
cpu: 500m
memory: 1Gi
limits:
cpu: 1000m
memory: 1Gi
volumeMounts:
- name: server-voices-pv
mountPath: /app/voices
- name: server-config-pv
mountPath: /app/config
volumes:
- name: server-voices-pv
persistentVolumeClaim:
claimName: server-voices-pvc
- name: server-config-pv
persistentVolumeClaim:
claimName: server-config-pvc
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: server-voices-pvc
labels:
app.kubernetes.io/name: server
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 5Gi
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: server-config-pvc
labels:
app.kubernetes.io/name: server
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

View File

@ -25,10 +25,16 @@ spec:
fieldPath: metadata.namespace
- name: OLLAMA_BASE_URL
value: http://ollama-server.$(NAMESPACE).svc:11434
- name: AUDIO_TTS_OPENAI_API_BASE_URL
value: http://openedai-speech-server.$(NAMESPACE).svc:8000/v1
- name: AUDIO_TTS_OPENAI_API_KEY
value: ignored
- name: RAG_EMBEDDING_ENGINE
value: ollama
- name: AUDIO_STT_ENGINE
- name: AUDIO_TTS_ENGINE
value: openai
# - name: AUDIO_STT_ENGINE
# value: openai
- name: ENABLE_SIGNUP
value: "false"
- name: ENABLE_OAUTH_SIGNUP
@ -57,8 +63,8 @@ spec:
# value: DEBUG
resources:
requests:
cpu: 250m
memory: 500Mi
cpu: 500m
memory: 1Gi
limits:
cpu: 500m
memory: 1Gi

View File

@ -1,6 +1,7 @@
resources:
- namespace.yaml
- ../../bases/ollama
- ../../bases/openedai-speech
# - ../../bases/litellm
- ../../bases/openwebui
- ../../bases/sillytavern