mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2026-06-27 23:50:20 -05:00
docker : prebuild web UI for s390x build [no release] (#24829)
This commit is contained in:
parent
796f41bedc
commit
67e9fd3b74
@ -4,20 +4,6 @@ ARG BUILD_DATE=N/A
|
|||||||
ARG APP_VERSION=N/A
|
ARG APP_VERSION=N/A
|
||||||
ARG APP_REVISION=N/A
|
ARG APP_REVISION=N/A
|
||||||
|
|
||||||
ARG NODE_VERSION=24
|
|
||||||
|
|
||||||
FROM docker.io/node:$NODE_VERSION AS web
|
|
||||||
|
|
||||||
ARG APP_VERSION
|
|
||||||
|
|
||||||
WORKDIR /app/tools/ui
|
|
||||||
|
|
||||||
COPY tools/ui/package.json tools/ui/package-lock.json ./
|
|
||||||
RUN npm ci
|
|
||||||
|
|
||||||
COPY tools/ui/ ./
|
|
||||||
RUN LLAMA_BUILD_NUMBER="$APP_VERSION" npm run build
|
|
||||||
|
|
||||||
### Build Llama.cpp stage
|
### Build Llama.cpp stage
|
||||||
FROM docker.io/gcc:${GCC_VERSION} AS build
|
FROM docker.io/gcc:${GCC_VERSION} AS build
|
||||||
|
|
||||||
@ -34,8 +20,6 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
|
|||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
COPY --from=web /app/tools/ui/dist tools/ui/dist
|
|
||||||
|
|
||||||
RUN --mount=type=cache,target=/root/.ccache \
|
RUN --mount=type=cache,target=/root/.ccache \
|
||||||
--mount=type=cache,target=/app/build \
|
--mount=type=cache,target=/app/build \
|
||||||
cmake -S . -B build -G Ninja \
|
cmake -S . -B build -G Ninja \
|
||||||
|
|||||||
@ -11,7 +11,6 @@
|
|||||||
build*/
|
build*/
|
||||||
|
|
||||||
tools/ui/node_modules/
|
tools/ui/node_modules/
|
||||||
tools/ui/dist/
|
|
||||||
|
|
||||||
models/*
|
models/*
|
||||||
|
|
||||||
|
|||||||
18
.github/workflows/docker.yml
vendored
18
.github/workflows/docker.yml
vendored
@ -58,6 +58,13 @@ jobs:
|
|||||||
git tag ${{ steps.srctag.outputs.name }} || exit 0
|
git tag ${{ steps.srctag.outputs.name }} || exit 0
|
||||||
git push origin ${{ steps.srctag.outputs.name }} || exit 0
|
git push origin ${{ steps.srctag.outputs.name }} || exit 0
|
||||||
|
|
||||||
|
build_ui:
|
||||||
|
name: Build UI
|
||||||
|
needs: create_tag
|
||||||
|
uses: ./.github/workflows/ui-build.yml
|
||||||
|
with:
|
||||||
|
hf_ui_version: ${{ needs.create_tag.outputs.source_tag }}
|
||||||
|
|
||||||
prepare_matrices:
|
prepare_matrices:
|
||||||
name: Prepare Docker matrices
|
name: Prepare Docker matrices
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
@ -79,7 +86,7 @@ jobs:
|
|||||||
[
|
[
|
||||||
{ "tag": "cpu", "dockerfile": ".devops/cpu.Dockerfile", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04" },
|
{ "tag": "cpu", "dockerfile": ".devops/cpu.Dockerfile", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04" },
|
||||||
{ "tag": "cpu", "dockerfile": ".devops/cpu.Dockerfile", "platforms": "linux/arm64", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04-arm" },
|
{ "tag": "cpu", "dockerfile": ".devops/cpu.Dockerfile", "platforms": "linux/arm64", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04-arm" },
|
||||||
{ "tag": "cpu", "dockerfile": ".devops/s390x.Dockerfile", "platforms": "linux/s390x", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04-s390x" },
|
{ "tag": "cpu", "dockerfile": ".devops/s390x.Dockerfile", "platforms": "linux/s390x", "full": true, "light": true, "server": true, "free_disk_space": false, "runs_on": "ubuntu-24.04-s390x", "prebuilt_ui": true },
|
||||||
{ "tag": "cuda cuda12", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "12.8.1", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04" },
|
{ "tag": "cuda cuda12", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "12.8.1", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04" },
|
||||||
{ "tag": "cuda cuda12", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "12.8.1", "platforms": "linux/arm64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04-arm" },
|
{ "tag": "cuda cuda12", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "12.8.1", "platforms": "linux/arm64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04-arm" },
|
||||||
{ "tag": "cuda13", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "13.3.0", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04" },
|
{ "tag": "cuda13", "dockerfile": ".devops/cuda.Dockerfile", "cuda_version": "13.3.0", "platforms": "linux/amd64", "full": true, "light": true, "server": true, "free_disk_space": true, "runs_on": "ubuntu-24.04" },
|
||||||
@ -135,7 +142,7 @@ jobs:
|
|||||||
|
|
||||||
push_to_registry:
|
push_to_registry:
|
||||||
name: Push Docker image to Docker Registry
|
name: Push Docker image to Docker Registry
|
||||||
needs: [prepare_matrices, create_tag]
|
needs: [prepare_matrices, create_tag, build_ui]
|
||||||
|
|
||||||
runs-on: ${{ matrix.config.runs_on }}
|
runs-on: ${{ matrix.config.runs_on }}
|
||||||
strategy:
|
strategy:
|
||||||
@ -150,6 +157,13 @@ jobs:
|
|||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
ref: ${{ needs.create_tag.outputs.source_tag }}
|
ref: ${{ needs.create_tag.outputs.source_tag }}
|
||||||
|
|
||||||
|
- name: Download prebuilt UI
|
||||||
|
if: ${{ matrix.config.prebuilt_ui == true }}
|
||||||
|
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8
|
||||||
|
with:
|
||||||
|
name: ui-build
|
||||||
|
path: tools/ui/dist
|
||||||
|
|
||||||
- name: Set up QEMU
|
- name: Set up QEMU
|
||||||
if: ${{ contains(matrix.config.platforms, 'linux/amd64') }}
|
if: ${{ contains(matrix.config.platforms, 'linux/amd64') }}
|
||||||
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4
|
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user