-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathDockerfile.ollama.stub
More file actions
24 lines (20 loc) · 914 Bytes
/
Dockerfile.ollama.stub
File metadata and controls
24 lines (20 loc) · 914 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# java engine
FROM eclipse-temurin:21-noble
# get the wiremock service
RUN wget https://repo1.maven.org/maven2/org/wiremock/wiremock-standalone/3.13.1/wiremock-standalone-3.13.1.jar
# setup the mappings
RUN mkdir mappings
# write the stubbing file
RUN echo '\
{\
"request": {\
"method": "GET",\
"url": "/api/tags"\
},\
"response": {\
"status": 200,\
"body": "{\"models\":[{\"name\":\"llama3.1:8b\",\"model\":\"llama3.1:8b\",\"modified_at\":\"2025-07-12T18:55:41.604224865Z\",\"size\":4920753328,\"digest\":\"46e0c10c039e019119339687c3c1757cc81b9da49709a3b3924863ba87ca666e\",\"details\":{\"parent_model\":\"\",\"format\":\"gguf\",\"family\":\"llama\",\"families\":[\"llama\"],\"parameter_size\":\"8.0B\",\"quantization_level\":\"Q4_K_M\"}}]}"\
}\
}' > ./mappings/get-api-tags.json
# start the stub server
CMD java -jar wiremock-standalone-3.13.1.jar --port 11434