Skip to content

Commit eb6f702

Browse files
committed
Add Dockerfile for musa, .dockerignore and update CI
Signed-off-by: Xiaodong Ye <[email protected]>
1 parent 4e5e791 commit eb6f702

File tree

3 files changed

+35
-0
lines changed

3 files changed

+35
-0
lines changed

.devops/main-musa.Dockerfile

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
ARG UBUNTU_VERSION=22.04
2+
# This needs to generally match the container host's environment.
3+
ARG MUSA_VERSION=rc3.1.1
4+
# Target the MUSA build image
5+
ARG BASE_MUSA_DEV_CONTAINER=mthreads/musa:${MUSA_VERSION}-devel-ubuntu${UBUNTU_VERSION}
6+
# Target the MUSA runtime image
7+
ARG BASE_MUSA_RUN_CONTAINER=mthreads/musa:${MUSA_VERSION}-runtime-ubuntu${UBUNTU_VERSION}
8+
9+
FROM ${BASE_MUSA_DEV_CONTAINER} AS build
10+
WORKDIR /app
11+
12+
# Enable muBLAS
13+
ENV GGML_MUSA=1
14+
15+
RUN apt-get update && \
16+
apt-get install -y build-essential libsdl2-dev wget cmake git \
17+
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/*
18+
19+
COPY .. .
20+
RUN make base.en
21+
22+
FROM ${BASE_MUSA_RUN_CONTAINER} AS runtime
23+
WORKDIR /app
24+
25+
RUN apt-get update && \
26+
apt-get install -y curl ffmpeg wget cmake git \
27+
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/*
28+
29+
COPY --from=build /app /app
30+
ENV PATH /app/build/bin:$PATH
31+
ENTRYPOINT [ "bash", "-c" ]

.dockerignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
build*/
2+
.github/
3+
.devops/

.github/workflows/docker.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ jobs:
1818
matrix:
1919
config:
2020
- { tag: "main", dockerfile: ".devops/main.Dockerfile", platform: "linux/amd64" }
21+
- { tag: "main-musa", dockerfile: ".devops/main-musa.Dockerfile", platform: "linux/amd64" }
2122
#TODO: the cuda image keeps failing - disable for now
2223
# https://github.com/ggerganov/whisper.cpp/actions/runs/11019444428/job/30602020339
2324
#- { tag: "main-cuda", dockerfile: ".devops/main-cuda.Dockerfile", platform: "linux/amd64" }

0 commit comments

Comments
 (0)