From 2c30555b844293764123baa4137fcf952d40a4e7 Mon Sep 17 00:00:00 2001 From: mauwii Date: Tue, 1 Nov 2022 01:34:20 +0100 Subject: [PATCH] update Dockerfile - create models.yaml from models.yaml.example - run preload_models.py with --no-interactive --- docker-build/Dockerfile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/docker-build/Dockerfile b/docker-build/Dockerfile index 2f0c892730..2de04b28b0 100644 --- a/docker-build/Dockerfile +++ b/docker-build/Dockerfile @@ -39,12 +39,12 @@ RUN apt-get update \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -# clone repository and create symlinks +# clone repository, create models.yaml and create symlinks ARG invokeai_git=https://github.com/invoke-ai/InvokeAI.git ARG project_name=invokeai RUN git clone ${invokeai_git} /${project_name} \ - && mkdir /${project_name}/models/ldm/stable-diffusion-v1 \ - && ln -s /data/models/sd-v1-4.ckpt /${project_name}/models/ldm/stable-diffusion-v1/model.ckpt \ + && cp /${project_name}/configs/models.yaml.example /${project_name}/configs/models.yaml \ + && ln -s /data/models/v1-5-pruned-emaonly.ckpt /${project_name}/models/ldm/stable-diffusion-v1/v1-5-pruned-emaonly.ckpt \ && ln -s /data/outputs/ /${project_name}/outputs # set workdir @@ -65,7 +65,8 @@ RUN source ${conda_prefix}/etc/profile.d/conda.sh \ && echo "conda activate ${project_name}" >> ~/.bashrc \ && ln -s /data/models/GFPGANv1.4.pth ./src/gfpgan/experiments/pretrained_models/GFPGANv1.4.pth \ && conda activate ${project_name} \ - && python scripts/preload_models.py + && python scripts/preload_models.py \ + --no-interactive # Copy entrypoint and set env ENV CONDA_PREFIX=${conda_prefix}