Gesprächsaufnahmen mit lokalem Whisper und LLM verarbeiten
This commit is contained in:
1 parent
373081d33d
commit
55e5d34e83
39 files changed
+2931
-74
No files matched your search
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
# Both services belong to this container. Stop the peer when either one exits.
|
||||
pids=()
|
||||
cleanup() {
|
||||
trap '' TERM INT
|
||||
kill -TERM "${pids[@]}" 2>/dev/null || true
|
||||
wait "${pids[@]}" 2>/dev/null || true
|
||||
}
|
||||
trap 'cleanup; exit 143' TERM
|
||||
trap 'cleanup; exit 130' INT
|
||||
|
||||
python -m uvicorn service:app --app-dir /app/transcription --host 127.0.0.1 --port 8765 &
|
||||
pids+=("$!")
|
||||
# JAVA_OPTS intentionally allows multiple JVM arguments.
|
||||
# shellcheck disable=SC2086
|
||||
java $JAVA_OPTS -jar /app/app.jar &
|
||||
pids+=("$!")
|
||||
|
||||
set +e
|
||||
wait -n "${pids[@]}"
|
||||
status=$?
|
||||
cleanup
|
||||
# Even an unexpected clean service exit should restart the container.
|
||||
if [ "$status" -eq 0 ]; then status=1; fi
|
||||
exit "$status"
|
||||
Reference in new issue
Block a user