[PR #1700] [CLOSED] Refactor builder dockerfile #15921

Closed
opened 2026-04-16 05:11:53 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/1700
Author: @dhiltgen
Created: 12/24/2023
Status: Closed

Base: mainHead: dockerfile


📝 Commits (1)

  • 10ba4c5 Refactor builder dockerfile

📊 Changes

2 files changed (+47 additions, -32 deletions)

View changed files

📝 Dockerfile.build (+38 -31)
📝 scripts/build_linux.sh (+9 -1)

📄 Description

Reorganize the x86/arm components to be more DRY, and remove the cuda driver

Note: to build locally on arm mac, I need to remove the --cache-from and --cache-to flags in the script to be able to build without a builder defined. It seems with a builder, qemu is being used instead of rosetta, and the rocm post-install packaging scripts have some binaries that wont run with qemu resulting in

...
#10 864.1 Error while loading /var/lib/dpkg/info/rocrand.postinst: Exec format error
#10 864.1 dpkg: error processing package rocrand (--configure):
#10 864.1  installed rocrand package post-installation script subprocess returned error exit status 1

If I omit creating a buildx builder, the default Docker Desktop build with rosetta works.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/1700 **Author:** [@dhiltgen](https://github.com/dhiltgen) **Created:** 12/24/2023 **Status:** ❌ Closed **Base:** `main` ← **Head:** `dockerfile` --- ### 📝 Commits (1) - [`10ba4c5`](https://github.com/ollama/ollama/commit/10ba4c529fba458dc9cebce90844208477538be5) Refactor builder dockerfile ### 📊 Changes **2 files changed** (+47 additions, -32 deletions) <details> <summary>View changed files</summary> 📝 `Dockerfile.build` (+38 -31) 📝 `scripts/build_linux.sh` (+9 -1) </details> ### 📄 Description Reorganize the x86/arm components to be more DRY, and remove the cuda driver Note: to build locally on arm mac, I need to remove the `--cache-from` and `--cache-to` flags in the script to be able to build without a builder defined. It seems with a builder, qemu is being used instead of rosetta, and the rocm post-install packaging scripts have some binaries that wont run with qemu resulting in ``` ... #10 864.1 Error while loading /var/lib/dpkg/info/rocrand.postinst: Exec format error #10 864.1 dpkg: error processing package rocrand (--configure): #10 864.1 installed rocrand package post-installation script subprocess returned error exit status 1 ``` If I omit creating a buildx builder, the default Docker Desktop build with rosetta works. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-16 05:11:53 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#15921