Skip to content

Commit 81708bb

Browse files
authored
fix: workaround exllama import error (#885)
Signed-off-by: Ettore Di Giacinto <[email protected]>
1 parent c81e9d8 commit 81708bb

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Dockerfile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,10 @@ RUN ESPEAK_DATA=/build/lib/Linux-$(uname -m)/piper_phonemize/lib/espeak-ng-data
108108
FROM requirements
109109

110110
ARG FFMPEG
111+
ARG BUILD_TYPE
112+
ARG TARGETARCH
111113

114+
ENV BUILD_TYPE=${BUILD_TYPE}
112115
ENV REBUILD=false
113116
ENV HEALTHCHECK_ENDPOINT=http://localhost:8080/readyz
114117

@@ -126,7 +129,10 @@ WORKDIR /build
126129
COPY . .
127130
RUN make prepare-sources
128131
COPY --from=builder /build/local-ai ./
129-
132+
# To resolve exllama import error
133+
RUN if [ "${BUILD_TYPE}" = "cublas" ] && [ "${TARGETARCH:-$(go env GOARCH)}" = "amd64" ]; then \
134+
cp -rfv /usr/local/lib/python3.9/dist-packages/exllama extra/grpc/exllama/;\
135+
fi
130136
# Define the health check command
131137
HEALTHCHECK --interval=1m --timeout=10m --retries=10 \
132138
CMD curl -f $HEALTHCHECK_ENDPOINT || exit 1

0 commit comments

Comments
 (0)