mirror of
https://github.com/openai/whisper.git
synced 2025-11-24 06:26:03 +00:00
fix: Consolidate nixpacks.toml to service directories for proper Railway deployment
This commit is contained in:
parent
f6f67ccbb8
commit
1f8e215ed5
11
farsi_transcriber_web/backend/nixpacks.toml
Normal file
11
farsi_transcriber_web/backend/nixpacks.toml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Backend Nixpacks configuration
|
||||||
|
# Ensures ffmpeg is available for Whisper audio processing
|
||||||
|
|
||||||
|
[phases.setup]
|
||||||
|
nixPkgs = ["ffmpeg"]
|
||||||
|
|
||||||
|
[phases.install]
|
||||||
|
cmds = ["pip install -r requirements.txt"]
|
||||||
|
|
||||||
|
[start]
|
||||||
|
cmd = "gunicorn --workers 2 --worker-class sync --timeout 120 --bind 0.0.0.0:$PORT app:app"
|
||||||
11
farsi_transcriber_web/nixpacks.toml
Normal file
11
farsi_transcriber_web/nixpacks.toml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Frontend Nixpacks configuration
|
||||||
|
# Node.js React app with Vite
|
||||||
|
|
||||||
|
[phases.install]
|
||||||
|
cmds = ["npm install"]
|
||||||
|
|
||||||
|
[phases.build]
|
||||||
|
cmds = ["npm run build"]
|
||||||
|
|
||||||
|
[start]
|
||||||
|
cmd = "npm run preview"
|
||||||
@ -1,11 +0,0 @@
|
|||||||
# Nixpacks configuration for Railway deployment
|
|
||||||
# Backend deployment with Whisper and ffmpeg
|
|
||||||
|
|
||||||
[phases.setup]
|
|
||||||
nixPkgs = ["ffmpeg"]
|
|
||||||
|
|
||||||
[phases.install]
|
|
||||||
cmds = ["cd farsi_transcriber_web/backend && pip install -r requirements.txt"]
|
|
||||||
|
|
||||||
[start]
|
|
||||||
cmd = "cd farsi_transcriber_web/backend && gunicorn --workers 2 --worker-class sync --timeout 120 --bind 0.0.0.0:$PORT app:app"
|
|
||||||
26
railway.toml
26
railway.toml
@ -1,26 +0,0 @@
|
|||||||
# Railway configuration for both backend and frontend services
|
|
||||||
# https://docs.railway.app/reference/nixpacks
|
|
||||||
|
|
||||||
[build]
|
|
||||||
builder = "nixpacks"
|
|
||||||
|
|
||||||
# Backend service configuration
|
|
||||||
[[services]]
|
|
||||||
name = "backend"
|
|
||||||
root = "farsi_transcriber_web/backend"
|
|
||||||
|
|
||||||
[services.build]
|
|
||||||
nixPkgs = ["ffmpeg"]
|
|
||||||
|
|
||||||
[services.build.nixPackages]
|
|
||||||
pythonPackages = ["pip"]
|
|
||||||
|
|
||||||
[services.start]
|
|
||||||
cmd = "gunicorn --workers 2 --worker-class sync --timeout 120 --bind 0.0.0.0:$PORT app:app"
|
|
||||||
|
|
||||||
# Frontend service configuration
|
|
||||||
[[services]]
|
|
||||||
name = "frontend"
|
|
||||||
root = "farsi_transcriber_web"
|
|
||||||
buildCommand = "npm install && npm run build"
|
|
||||||
startCommand = "npm run preview"
|
|
||||||
Loading…
x
Reference in New Issue
Block a user