-
Notifications
You must be signed in to change notification settings - Fork 27
/
start-nobuild.sh
executable file
·33 lines (26 loc) · 1.13 KB
/
start-nobuild.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
# Display initial message
echo "This script will start pull the needed docker images and start Transcription Stream."
echo "Please note the main image, ts-gpu, is nearly 26GB and may take a hot second to download."
echo "-- it also checks for latest mistral model then connects you to the logs"
echo -n "Do you want to continue? (y/n): "
# Read user input
read answer
# Check if the user input is 'y' or 'Y'
if [ "$answer" != "${answer#[Yy]}" ] ;then
# Create necessary Docker volume
echo "Creating Docker volume..."
docker volume create --name=transcriptionstream
# Start the docker-compose services
echo "Starting services with docker-compose..."
docker-compose -f docker-compose-nobuild.yml up --detach
# If running ts-gpt ollama container, enable this
# # Get the model installed on ts-gpt (requires curl)
echo "Downloading mistral model"
curl -X POST http://localhost:11434/api/pull -d '{"name": "transcriptionstream/transcriptionstream"}'
# Re-attach to compose logs
echo "Re-attaching to console logs"
docker-compose logs -f
else
echo "Installation canceled by the user."
fi