mirror of
https://github.com/mudler/LocalAI.git
synced 2024-12-24 06:46:39 +00:00
fix(Dockerfile): try to save some space
Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
This commit is contained in:
parent
94f20e2eb7
commit
fd28252e55
17
Dockerfile
17
Dockerfile
@ -19,7 +19,7 @@ ENV GALLERIES='[{"name":"model-gallery", "url":"github:go-skynet/model-gallery/i
|
|||||||
ARG GO_TAGS="stablediffusion tts"
|
ARG GO_TAGS="stablediffusion tts"
|
||||||
|
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get install -y ca-certificates curl patch pip cmake
|
apt-get install -y ca-certificates curl patch pip cmake && apt-get clean
|
||||||
|
|
||||||
|
|
||||||
# Use the variables in subsequent instructions
|
# Use the variables in subsequent instructions
|
||||||
@ -34,17 +34,18 @@ RUN if [ "${BUILD_TYPE}" = "cublas" ]; then \
|
|||||||
dpkg -i cuda-keyring_1.0-1_all.deb && \
|
dpkg -i cuda-keyring_1.0-1_all.deb && \
|
||||||
rm -f cuda-keyring_1.0-1_all.deb && \
|
rm -f cuda-keyring_1.0-1_all.deb && \
|
||||||
apt-get update && \
|
apt-get update && \
|
||||||
apt-get install -y cuda-nvcc-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcublas-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcusparse-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcusolver-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} \
|
apt-get install -y cuda-nvcc-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcublas-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcusparse-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} libcusolver-dev-${CUDA_MAJOR_VERSION}-${CUDA_MINOR_VERSION} && apt-get clean \
|
||||||
; fi
|
; fi
|
||||||
ENV PATH /usr/local/cuda/bin:${PATH}
|
ENV PATH /usr/local/cuda/bin:${PATH}
|
||||||
|
|
||||||
# OpenBLAS requirements
|
# OpenBLAS requirements and stable diffusion
|
||||||
RUN apt-get install -y libopenblas-dev
|
RUN apt-get install -y \
|
||||||
|
libopenblas-dev \
|
||||||
# Stable Diffusion requirements
|
libopencv-dev \
|
||||||
RUN apt-get install -y libopencv-dev && \
|
&& apt-get clean
|
||||||
ln -s /usr/include/opencv4/opencv2 /usr/include/opencv2
|
|
||||||
|
|
||||||
|
# Set up OpenCV
|
||||||
|
RUN ln -s /usr/include/opencv4/opencv2 /usr/include/opencv2
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user