mirror of
https://github.com/kodxana/madiator-docker-runpod.git
synced 2024-11-21 18:30:12 +01:00
Added Better Ollama template
This commit is contained in:
parent
00366c86e4
commit
656abb6292
4 changed files with 101 additions and 0 deletions
32
official-templates/better-ollama/Dockerfile
Normal file
32
official-templates/better-ollama/Dockerfile
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
# Base Image
|
||||||
|
FROM madiator2011/better-pytorch:cuda12.1
|
||||||
|
|
||||||
|
# Install necessary dependencies
|
||||||
|
RUN apt-get update && \
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
curl \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Download and install Ollama
|
||||||
|
RUN curl -L https://ollama.com/download/ollama-linux-amd64 -o /usr/bin/ollama && \
|
||||||
|
chmod +x /usr/bin/ollama
|
||||||
|
|
||||||
|
COPY settings.json /root/.local/share/code-server/User/settings.json
|
||||||
|
COPY tasks.json /root/.local/share/code-server/User/tasks.json
|
||||||
|
|
||||||
|
# Start Scripts
|
||||||
|
COPY --from=scripts start.sh /
|
||||||
|
RUN chmod +x /start.sh
|
||||||
|
|
||||||
|
# Set environment variables for runtime
|
||||||
|
ENV OLLAMA_HOST=0.0.0.0
|
||||||
|
ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||||
|
ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64
|
||||||
|
ENV NVIDIA_DRIVER_CAPABILITIES=compute,utility
|
||||||
|
ENV NVIDIA_VISIBLE_DEVICES=all
|
||||||
|
|
||||||
|
# Expose the required port
|
||||||
|
EXPOSE 11434
|
||||||
|
|
||||||
|
|
||||||
|
CMD ["/start.sh"]
|
18
official-templates/better-ollama/docker-bake.hcl
Normal file
18
official-templates/better-ollama/docker-bake.hcl
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
group "default" {
|
||||||
|
targets = ["py310-cuda121"]
|
||||||
|
}
|
||||||
|
|
||||||
|
target "py310-cuda121" {
|
||||||
|
contexts = {
|
||||||
|
scripts = "../../container-template"
|
||||||
|
proxy = "../../container-template/proxy"
|
||||||
|
logo = "../../container-template"
|
||||||
|
}
|
||||||
|
dockerfile = "Dockerfile"
|
||||||
|
args = {
|
||||||
|
BASE_IMAGE = "madiator2011/better-pytorch:cuda12.1",
|
||||||
|
TORCH = "torch==2.3.0+cu121 -f https://download.pytorch.org/whl/torch_stable.html",
|
||||||
|
PYTHON_VERSION = "3.10"
|
||||||
|
}
|
||||||
|
tags = ["madiator2011/better-ollama:cuda12.1"]
|
||||||
|
}
|
36
official-templates/better-ollama/settings.json
Normal file
36
official-templates/better-ollama/settings.json
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
{
|
||||||
|
"workbench.colorTheme": "Default Dark Modern",
|
||||||
|
"workbench.startupEditor": "none",
|
||||||
|
"workbench.enableExperiments": false,
|
||||||
|
"telemetry.enableTelemetry": false,
|
||||||
|
"telemetry.enableCrashReporter": false,
|
||||||
|
"security.workspace.trust.enabled": false,
|
||||||
|
"update.mode": "manual",
|
||||||
|
"extensions.autoUpdate": false,
|
||||||
|
"python.showStartPage": false,
|
||||||
|
"jupyter.experiments.enabled": false,
|
||||||
|
"jupyter.askForKernelRestart": false,
|
||||||
|
"jupyter.askForKernelSource": false,
|
||||||
|
"jupyter.alwaysTrustNotebooks": true,
|
||||||
|
"extensions.ignoreRecommendations": true,
|
||||||
|
"files.autoSave": "afterDelay",
|
||||||
|
"files.autoSaveDelay": 1000,
|
||||||
|
"terminal.integrated.defaultProfile.linux": "bash",
|
||||||
|
"terminal.integrated.profiles.linux": {
|
||||||
|
"bash": {
|
||||||
|
"path": "/bin/bash",
|
||||||
|
"args": []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"workbench.startupEditor": "none",
|
||||||
|
"workbench.panel.defaultLocation": "bottom",
|
||||||
|
"terminal.integrated.showLinkHover": true,
|
||||||
|
"terminal.integrated.tabs.enabled": true,
|
||||||
|
"terminal.integrated.enableBell": true,
|
||||||
|
"terminal.integrated.scrollback": 1000,
|
||||||
|
"extensions.autoCheckUpdates": false,
|
||||||
|
"extensions.autoUpdate": false,
|
||||||
|
"terminal.integrated.shellArgs.linux": [
|
||||||
|
"-c", "code -r . --run-task=\"Open Terminal\""
|
||||||
|
]
|
||||||
|
}
|
15
official-templates/better-ollama/tasks.json
Normal file
15
official-templates/better-ollama/tasks.json
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{
|
||||||
|
"version": "2.0.0",
|
||||||
|
"tasks": [
|
||||||
|
{
|
||||||
|
"label": "Open Terminal",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "echo 'Terminal Opened'",
|
||||||
|
"problemMatcher": [],
|
||||||
|
"presentation": {
|
||||||
|
"reveal": "always",
|
||||||
|
"panel": "shared"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
Loading…
Reference in a new issue