full-musa.Dockerfile 833 B

1234567891011121314151617181920212223242526
  1. ARG UBUNTU_VERSION=22.04
  2. # This needs to generally match the container host's environment.
  3. ARG MUSA_VERSION=rc3.1.0
  4. # Target the MUSA build image
  5. ARG BASE_MUSA_DEV_CONTAINER=mthreads/musa:${MUSA_VERSION}-devel-ubuntu${UBUNTU_VERSION}
  6. FROM ${BASE_MUSA_DEV_CONTAINER} AS build
  7. RUN apt-get update && \
  8. apt-get install -y build-essential cmake python3 python3-pip git libcurl4-openssl-dev libgomp1
  9. COPY requirements.txt requirements.txt
  10. COPY requirements requirements
  11. RUN pip install --upgrade pip setuptools wheel \
  12. && pip install -r requirements.txt
  13. WORKDIR /app
  14. COPY . .
  15. RUN cmake -B build -DGGML_MUSA=ON -DLLAMA_CURL=ON ${CMAKE_ARGS} -DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined . && \
  16. cmake --build build --config Release -j$(nproc) && \
  17. cp build/bin/* .
  18. ENTRYPOINT ["/app/.devops/tools.sh"]