mirror of
https://github.com/mudler/LocalAI.git
synced 2025-05-20 18:45:00 +00:00
fix: missing OpenCL libraries from docker containers during clblas docker build (#1830)
This commit is contained in:
parent
f82065703d
commit
a6b540737f
2 changed files with 15 additions and 0 deletions
|
@ -3,3 +3,4 @@ models
|
||||||
examples/chatbot-ui/models
|
examples/chatbot-ui/models
|
||||||
examples/rwkv/models
|
examples/rwkv/models
|
||||||
examples/**/models
|
examples/**/models
|
||||||
|
Dockerfile
|
14
Dockerfile
14
Dockerfile
|
@ -105,6 +105,13 @@ COPY . .
|
||||||
COPY .git .
|
COPY .git .
|
||||||
RUN make prepare
|
RUN make prepare
|
||||||
|
|
||||||
|
# If we are building with clblas support, we need the libraries for the builds
|
||||||
|
RUN if [ "${BUILD_TYPE}" = "clblas" ]; then \
|
||||||
|
apt-get update && \
|
||||||
|
apt-get install -y libclblast-dev && \
|
||||||
|
apt-get clean \
|
||||||
|
; fi
|
||||||
|
|
||||||
# stablediffusion does not tolerate a newer version of abseil, build it first
|
# stablediffusion does not tolerate a newer version of abseil, build it first
|
||||||
RUN GRPC_BACKENDS=backend-assets/grpc/stablediffusion make build
|
RUN GRPC_BACKENDS=backend-assets/grpc/stablediffusion make build
|
||||||
|
|
||||||
|
@ -148,6 +155,13 @@ RUN if [ "${FFMPEG}" = "true" ]; then \
|
||||||
apt-get install -y ffmpeg && apt-get clean \
|
apt-get install -y ffmpeg && apt-get clean \
|
||||||
; fi
|
; fi
|
||||||
|
|
||||||
|
# Add OpenCL
|
||||||
|
RUN if [ "${BUILD_TYPE}" = "clblas" ]; then \
|
||||||
|
apt-get update && \
|
||||||
|
apt-get install -y libclblast1 && \
|
||||||
|
apt-get clean \
|
||||||
|
; fi
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
|
|
||||||
# we start fresh & re-copy all assets because `make build` does not clean up nicely after itself
|
# we start fresh & re-copy all assets because `make build` does not clean up nicely after itself
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue