This project provides a Docker image and a sample docker-compose.yml configuration for running Ollama with Vulkan as the backend for executing LLM models. The setup ensures the necessary paths and dependencies are correctly configured to leverage Vulkan for optimized model execution.
Leveraging Vulkan for LLM model execution allows for improved performance on compatible hardware, providing a more efficient and scalable way to run machine learning workloads. This setup is designed to facilitate easy deployment and testing of Ollama with Vulkan support in a containerized environment.
- Pre-configured Docker image for Ollama with Vulkan support.
- Sample
docker-compose.ymlfor quick deployment. - Hardware acceleration via Vulkan for enhanced performance.
- Integration with Open WebUI for an accessible user interface.
- Docker
- Docker Compose
- A Vulkan-compatible GPU and drivers installed on the host machine.
git clone https://github.com/your-repo/ollama-vulkan-docker.git
cd ollama-vulkan-dockerA prebuilt Docker image is available at:
docker pull ghcr.io/wilgnne/ollama-vulkandocker-compose up -d --buildThis command will build the Ollama Vulkan image and start the services, exposing the Ollama API on port 11434 and the WebUI on 8080.
- Ollama API:
http://localhost:11434 - Open WebUI:
http://localhost:8080
| Variable | Default Value | Description |
|---|---|---|
OLLAMA_HOST |
0.0.0.0 |
Ollama API bind address |
WEBUI_AUTH |
False |
Disable authentication for WebUI |
WEBUI_URL |
http://localhost:8080 |
WebUI service URL |
- Ensure your user is part of the
videogroup to allow Vulkan access. - Modify the
group_addentry indocker-compose.ymlto match your system’s render group ID. - If experiencing GPU detection issues, try running the container with
privileged: trueenabled.
To stop and remove all running containers:
docker-compose downSpecial thanks to the following contributors:
Contributions are welcome! Feel free to submit pull requests or open issues to enhance the functionality or fix any bugs.
This project is licensed under the MIT License - see the LICENSE file for details.