text-generation-inference/Dockerfile.nix
Daniël de Kok b806a856c7 Stream to make the builder image smaller
This avoids storing a Docker image tarball in the image. Instead,
stream the layers while doing `docker run`.
2024-09-29 12:35:56 +02:00

14 lines
400 B
Nix

# Build the image and get out the docker file:
#
# docker build -t tgi-nix-builder -f Dockerfile.nix
# docker run tgi-nix-builder | docker load
FROM nixos/nix:2.18.8
RUN echo "experimental-features = nix-command flakes" >> /etc/nix/nix.conf
RUN nix profile install nixpkgs#cachix
RUN cachix use text-generation-inference
WORKDIR /root
ADD . .
RUN nix build .#dockerImageStreamed
ENTRYPOINT ./result