FROM nvidia/cuda:11.8.0-devel-ubuntu22.04 RUN apt update && apt install git build-essential libopenblas-dev wget python3-pip -y RUN apt update && apt install -y wget ARG MODEL_PART_A ARG MODEL_PART_B ARG MODEL_NAME ARG ADDITIONAL RUN mkdir /opt/koboldcpp RUN apt update && apt install git build-essential libopenblas-dev wget python3-pip -y RUN git clone https://github.com/lostruins/koboldcpp /opt/koboldcpp WORKDIR /opt/koboldcpp COPY default.json /opt/koboldcpp/default.json RUN make LLAMA_OPENBLAS=1 LLAMA_CUBLAS=1 LLAMA_PORTABLE=1 RUN wget -O part_a.gguf $MODEL_PART_A RUN wget -O part_b.gguf $MODEL_PART_B RUN cat part_a.gguf part_b.gguf > model.gguf RUN rm part_a.gguf part_b.gguf CMD /bin/python3 ./koboldcpp.py --model model.gguf $ADDITIONAL --port 7860 --hordeconfig $MODEL_NAME 1 1 --preloadstory default.json