Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ songbird = { version = "0.6", default-features = false, features = ["driver", "g
sqlx = { package = "sqlx-core", version = "0.8", default-features = false, features = ["_rt-tokio", "_tls-rustls-ring-webpki", "chrono", "json"] }
sqlx-postgres = { version = "0.8", features = ["chrono", "json"] }
tokio = { version = "1.47", features = ["fs", "macros", "net", "process", "rt-multi-thread", "signal", "sync", "time"] }
tower-http = { version = "0.6", features = ["cors", "trace"] }
tower-http = { version = "0.6", features = ["cors", "fs", "trace"] }
tracing = "0.1"
uuid = { version = "1.18", features = ["v4", "serde"] }
walkdir = "2.5"
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ RUN apt-get update \
COPY --from=builder /workspace/target/release/call-scribe /usr/local/bin/call-scribe
COPY LICENSE /usr/share/doc/call-scribe/LICENSE
COPY --from=builder /workspace/THIRD_PARTY_LICENSES.html /usr/share/doc/call-scribe/THIRD_PARTY_LICENSES.html
COPY web /usr/share/call-scribe/web

USER callscribe
WORKDIR /app
ENV CALL_SCRIBE_WEB_DIR=/usr/share/call-scribe/web
ENTRYPOINT ["call-scribe"]
125 changes: 125 additions & 0 deletions charts/call-scribe/templates/api-deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
{{- if .Values.api.enabled }}
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "call-scribe.fullname" . }}-api
labels:
{{- include "call-scribe.labels" . | nindent 4 }}
app.kubernetes.io/component: api
spec:
replicas: {{ .Values.api.replicaCount }}
selector:
matchLabels:
{{- include "call-scribe.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: api
template:
metadata:
labels:
{{- include "call-scribe.selectorLabels" . | nindent 8 }}
app.kubernetes.io/component: api
spec:
automountServiceAccountToken: {{ .Values.automountServiceAccountToken }}
securityContext:
runAsNonRoot: true
runAsUser: 10001
runAsGroup: 10001
fsGroup: 10001
fsGroupChangePolicy: OnRootMismatch
seccompProfile:
type: RuntimeDefault
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: call-scribe-api
image: {{ include "call-scribe.image" . | quote }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
args:
- serve
ports:
- name: http
containerPort: {{ .Values.api.port }}
envFrom:
- secretRef:
name: {{ .Values.providerCredentials.existingSecret | quote }}
optional: true
env:
- name: CALL_SCRIBE_DATABASE_URL
valueFrom:
secretKeyRef:
name: {{ .Values.database.existingSecret | quote }}
key: {{ .Values.database.urlKey | quote }}
- name: CALL_SCRIBE_API_BIND
value: {{ printf "0.0.0.0:%v" .Values.api.port | quote }}
- name: CALL_SCRIBE_MEETINGS_DIR
value: {{ .Values.api.meetingsDir | quote }}
- name: CALL_SCRIBE_WEB_DIR
value: {{ .Values.api.webDir | quote }}
- name: CALL_SCRIBE_STT_PROVIDER
value: {{ .Values.config.sttProvider | quote }}
- name: CALL_SCRIBE_ORGANIZATION_ID
value: {{ .Values.config.organizationId | quote }}
- name: CALL_SCRIBE_CAPTURE_MODE
value: {{ .Values.config.captureMode | quote }}
{{- if .Values.api.devAuthSub }}
- name: CALL_SCRIBE_DEV_AUTH_SUB
value: {{ .Values.api.devAuthSub | quote }}
{{- end }}
{{- if .Values.api.oidcIssuer }}
- name: CALL_SCRIBE_OIDC_ISSUER
value: {{ .Values.api.oidcIssuer | quote }}
{{- end }}
{{- if .Values.api.oidcAudience }}
- name: CALL_SCRIBE_OIDC_AUDIENCE
value: {{ .Values.api.oidcAudience | quote }}
{{- end }}
- name: ELEVENLABS_STT_TIMEOUT_SECONDS
value: {{ .Values.config.sttTimeoutSeconds | quote }}
- name: ELEVENLABS_STT_DIARIZE
value: {{ .Values.config.sttDiarize | quote }}
readinessProbe:
httpGet:
path: /healthz
port: http
initialDelaySeconds: 5
periodSeconds: 10
livenessProbe:
httpGet:
path: /healthz
port: http
initialDelaySeconds: 15
periodSeconds: 20
securityContext:
allowPrivilegeEscalation: false
readOnlyRootFilesystem: true
capabilities:
drop:
- ALL
volumeMounts:
- name: meetings
mountPath: /meetings
- name: tmp
mountPath: /tmp
resources:
{{- toYaml .Values.api.resources | nindent 12 }}
volumes:
- name: meetings
persistentVolumeClaim:
claimName: {{ include "call-scribe.fullname" . }}
- name: tmp
emptyDir:
sizeLimit: 1Gi
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
20 changes: 20 additions & 0 deletions charts/call-scribe/templates/api-networkpolicy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{{- if and .Values.api.enabled .Values.networkPolicy.enabled }}
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: {{ include "call-scribe.fullname" . }}-api-allow-ingress
labels:
{{- include "call-scribe.labels" . | nindent 4 }}
app.kubernetes.io/component: api
spec:
podSelector:
matchLabels:
{{- include "call-scribe.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: api
policyTypes:
- Ingress
ingress:
- ports:
- protocol: TCP
port: {{ .Values.api.port }}
{{- end }}
18 changes: 18 additions & 0 deletions charts/call-scribe/templates/api-service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{{- if .Values.api.enabled }}
apiVersion: v1
kind: Service
metadata:
name: {{ include "call-scribe.fullname" . }}-api
labels:
{{- include "call-scribe.labels" . | nindent 4 }}
app.kubernetes.io/component: api
spec:
type: ClusterIP
selector:
{{- include "call-scribe.selectorLabels" . | nindent 4 }}
app.kubernetes.io/component: api
ports:
- name: http
port: {{ .Values.api.port }}
targetPort: http
{{- end }}
3 changes: 3 additions & 0 deletions charts/call-scribe/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,20 @@ metadata:
name: {{ include "call-scribe.fullname" . }}
labels:
{{- include "call-scribe.labels" . | nindent 4 }}
app.kubernetes.io/component: worker
spec:
replicas: {{ .Values.replicaCount }}
strategy:
type: Recreate
selector:
matchLabels:
{{- include "call-scribe.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: worker
template:
metadata:
labels:
{{- include "call-scribe.selectorLabels" . | nindent 8 }}
app.kubernetes.io/component: worker
spec:
automountServiceAccountToken: {{ .Values.automountServiceAccountToken }}
terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }}
Expand Down
26 changes: 26 additions & 0 deletions charts/call-scribe/templates/httproute.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{{- if and .Values.api.enabled .Values.api.httpRoute.enabled }}
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
name: {{ include "call-scribe.fullname" . }}-ui
labels:
{{- include "call-scribe.labels" . | nindent 4 }}
app.kubernetes.io/component: api
spec:
parentRefs:
- name: {{ .Values.api.httpRoute.gatewayName }}
namespace: {{ .Values.api.httpRoute.gatewayNamespace }}
sectionName: {{ .Values.api.httpRoute.sectionName }}
hostnames:
{{- range .Values.api.httpRoute.hostnames }}
- {{ . | quote }}
{{- end }}
rules:
- matches:
- path:
type: PathPrefix
value: /
backendRefs:
- name: {{ include "call-scribe.fullname" . }}-api
port: {{ .Values.api.port }}
{{- end }}
2 changes: 2 additions & 0 deletions charts/call-scribe/templates/networkpolicy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ spec:
podSelector:
matchLabels:
{{- include "call-scribe.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: worker
policyTypes:
- Ingress
ingress: []
{{- end }}

25 changes: 25 additions & 0 deletions charts/call-scribe/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,31 @@ config:
captureMode: record-only
organizationId: org_private_alpha

api:
enabled: false
replicaCount: 1
port: 8080
meetingsDir: /meetings
webDir: /usr/share/call-scribe/web
# Private-alpha convenience auth subject. Leave empty for real OIDC only.
devAuthSub: ""
oidcIssuer: ""
oidcAudience: ""
resources:
requests:
cpu: 100m
memory: 256Mi
limits:
cpu: "1"
memory: 1Gi
httpRoute:
enabled: false
gatewayName: gateway
gatewayNamespace: gateway
sectionName: https-callscribe-hazyforge-io
hostnames:
- callscribe.hazyforge.io

persistence:
storageClassName: ""
accessModes:
Expand Down
Loading
Loading