remove docker from script
This commit is contained in:
parent
67dfb30647
commit
75d6868427
1 changed files with 13 additions and 12 deletions
|
|
@ -7,6 +7,7 @@ set -e
|
||||||
|
|
||||||
# Get the directory where this script is located
|
# Get the directory where this script is located
|
||||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||||
|
PROJECT_DIR="$(dirname "$SCRIPT_DIR")"
|
||||||
|
|
||||||
# Load GROQ_API_KEY
|
# Load GROQ_API_KEY
|
||||||
source "$SCRIPT_DIR/.env"
|
source "$SCRIPT_DIR/.env"
|
||||||
|
|
@ -14,8 +15,7 @@ export GROQ_API_KEY
|
||||||
|
|
||||||
# Stop existing services
|
# Stop existing services
|
||||||
lsof -ti:8880 | xargs -r kill -9 2>/dev/null || true
|
lsof -ti:8880 | xargs -r kill -9 2>/dev/null || true
|
||||||
docker stop openreader-webui 2>/dev/null || true
|
lsof -ti:3003 | xargs -r kill -9 2>/dev/null || true
|
||||||
docker rm openreader-webui 2>/dev/null || true
|
|
||||||
sleep 1
|
sleep 1
|
||||||
|
|
||||||
# Start Groq TTS proxy (adds /voices endpoint for OpenReader)
|
# Start Groq TTS proxy (adds /voices endpoint for OpenReader)
|
||||||
|
|
@ -28,16 +28,17 @@ if ! curl -s http://localhost:8880/ > /dev/null; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Run OpenReader WebUI
|
# Build and run OpenReader WebUI
|
||||||
docker run --name openreader-webui \
|
cd "$PROJECT_DIR"
|
||||||
--restart unless-stopped \
|
pnpm install
|
||||||
--add-host=host.docker.internal:host-gateway \
|
pnpm build
|
||||||
-e API_KEY=none \
|
|
||||||
-e API_BASE=http://host.docker.internal:8880/v1 \
|
# Set environment variables for the app
|
||||||
-p 3003:3003 \
|
export API_KEY=none
|
||||||
-v openreader_docstore:/app/docstore \
|
export API_BASE=http://localhost:8880/v1
|
||||||
-d \
|
|
||||||
ghcr.io/richardr1126/openreader-webui:latest
|
# Start the app
|
||||||
|
pnpm start &
|
||||||
|
|
||||||
echo "OpenReader WebUI started at http://localhost:3003"
|
echo "OpenReader WebUI started at http://localhost:3003"
|
||||||
echo "Groq TTS proxy running on port 8880"
|
echo "Groq TTS proxy running on port 8880"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue