thewise commited on
Commit
a5ae591
1 Parent(s): 4b182fe

Update entrypoint.sh

Browse files
Files changed (1) hide show
  1. entrypoint.sh +16 -1
entrypoint.sh CHANGED
@@ -1,6 +1,21 @@
1
  #!/bin/bash
 
 
2
  echo "Starting server"
3
  ollama serve &
4
  sleep 1
 
 
5
  echo "Pulling $model"
6
- ollama pull $model # model here
 
 
 
 
 
 
 
 
 
 
 
 
1
  #!/bin/bash
2
+
3
+ # Start the server in the background
4
  echo "Starting server"
5
  ollama serve &
6
  sleep 1
7
+
8
+ # Pull the specified model
9
  echo "Pulling $model"
10
+ ollama pull $model
11
+
12
+ # Wait a bit for the model to be ready
13
+ sleep 5
14
+
15
+ # Run the specified model
16
+ echo "Running $model"
17
+ ollama run $model
18
+
19
+ # Keep the script running to prevent the container from exiting
20
+ # Adjust the command below as needed based on your application's behavior
21
+ wait