No related to Invoke AI docker in community app (Still Works as of July 2026) This is a simple unofficial Docker for Unraid (with most data stored in appdata and uses git pull, this helps base image to not need constant updates) for InvokeAI: A Stable Diffusion Toolkit, on start it will check for updates from git, update python venv if changes are needed and auto start the web ui This Docker is using the main branch of InvokeAI, as it is getting updated all the time, things might break every now and then check out their hard work @ https://github.com/invoke-ai/InvokeAI - Changelog or join the InvokeAI discord https://discord.gg/ZmtBAhwWhy https://github.com/invoke-ai/InvokeAI/releases I Know only a small amount about making a docker so this is probably not the right way as I just used google to work it all out, but it worked for me, thought others might find it useful. My Opinion For best Experience (may or may not run on other hardware): Minimal Requirements: A Nvidia GPU with at least 6gb Vram, at least a Pascal based cards, 12gb free system ram, 20gb storage space Recommended requirements: A Nvidia GPU with 8gb+ Vram, Turing based cards+, 16gb+ free system ram, 40gb+ storage space There is now 2 Options to make the docker container: Option 1 - Simplified Install (using Docker Hub) 1. building the docker container make a file called my-invokeai.xml or my-invokeai_prenodes.xml in \config\plugins\dockerMan\templates-user (on your unraid flash drive) add the text below from one of the options below to it and save then go to your unraid gui and then the docker tab, click "add container", in template dropdown box select your user template "invokeai" change port/host paths if required add your hugging face access token if you wish to have auto download of some models/concepts/diffusers <?xml version="1.0"?>
<Container version="2">
<Name>InvokeAI</Name>
<Repository>mickr777/invokeai_unraid_main</Repository>
<Registry>https://hub.docker.com/r/mickr777/invokeai_unraid_main</Registry>
<Network>bridge</Network>
<MyIP/>
<Shell>bash</Shell>
<Privileged>false</Privileged>
<Support>https://forums.unraid.net/topic/130913-guide-invokeai-a-stable-diffusion-toolkit-docker/</Support>
<Project>https://github.com/invoke-ai/InvokeAI/</Project>
<Overview>Simplified Docker with auto update for InvokeAI and Unraid.</Overview>
<Category>Other: Status:Beta</Category>
<WebUI>http://[IP]:[PORT:9090]/</WebUI>
<TemplateURL/>
<Icon>https://i.ibb.co/N2c008N/invokeai.png</Icon>
<ExtraParams>--gpus all</ExtraParams>
<PostArgs/>
<CPUset/>
<DateInstalled/>
<DonateText/>
<DonateLink/>
<Requires/>
<Config Name="InvokeAI" Target="/home/invokeuser/InvokeAI/" Default="/mnt/cache/appdata/invokeai/invokeai/" Mode="rw" Description="InvokeAI source code path" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/invokeai/</Config>
<Config Name="userfiles" Target="/home/invokeuser/userfiles/" Default="/mnt/cache/appdata/invokeai/userfiles/" Mode="rw" Description="Persistent storage for models, configs, and outputs" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/userfiles/</Config>
<Config Name="venv" Target="/home/invokeuser/venv/" Default="/mnt/cache/appdata/invokeai/venv/" Mode="rw" Description="Python virtual environment storage" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/venv/</Config>
<Config Name="cache" Target="/home/invokeuser/.cache" Default="/mnt/user/appdata/invokeai/cache" Mode="rw" Description="Cache directory (e.g., Hugging Face models)" Type="Path" Display="always" Required="true" Mask="false">/mnt/user/appdata/invokeai/cache</Config>
<Config Name="Webui Port" Target="9090" Default="9090" Mode="tcp" Description="WebUI port" Type="Port" Display="always" Required="true" Mask="false">9090</Config>
</Container> 2. Last steps after container build, on first run the python venv will be created and the preload of some models/weights/diffusers (this can take a while and will download 20gb+ of data, open docker log for progress) once this is done load up any web browser and point it to [Your Unraid IP]:9090 (or the port you set) --------------------------------------------------------------------------------------------- Option 2 - Full Manual Install - Main Branch (or just want to see what i did to get it to work) 1. First we will create the needed files create a folder on one of the drive's on you unraid server (I named mine invokeai) inside that folder create a text file called Dockerfile (make sure you remove the txt extension if it has one) add this info in to it and save: FROM ubuntu:24.04
RUN apt-get update \
&& DEBIAN_FRONTEND="noninteractive" \
apt-get install -y \
git \
dos2unix \
python3-pip \
python3-venv \
libopencv-dev \
sudo \
&& apt-get clean
RUN apt-get install -y curl sudo
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash - && sudo apt-get install -y nodejs
RUN npm install -g pnpm
RUN useradd --create-home -u 99 -g 100 invokeuser && \
chown -R 99:100 /home/invokeuser
WORKDIR /home/invokeuser
ADD start.sh .
RUN dos2unix start.sh
RUN chmod +x start.sh
USER invokeuser
WORKDIR /home/invokeuser
ADD invokeai.yaml .
ENTRYPOINT ["/bin/bash", "start.sh"] then create a text file called start.sh add this info in to it and click save: #!/bin/bash
# Sets a variable for the home directory
HOMEDIR="/home/invokeuser"
# Checks if the git repo has been cloned and clones it if needed
if [ -f "$HOMEDIR/InvokeAI/pyproject.toml" ]; then
git config --global --add safe.directory "$HOMEDIR/InvokeAI"
cd "$HOMEDIR/InvokeAI" || exit
else
echo "Cloning Git Repo into Local Folder..."
git config --global --add safe.directory "$HOMEDIR/InvokeAI"
git clone -b main https://github.com/invoke-ai/InvokeAI.git InvokeAI
cd "$HOMEDIR/InvokeAI" || exit
fi
# Checks if Python Environment has been made and creates it if it has not
if [ -f "$HOMEDIR/venv/pyvenv.cfg" ]; then
source "$HOMEDIR/venv/bin/activate"
else
echo "Creating Python Environment...."
python3 -m venv "$HOMEDIR/venv/"
source "$HOMEDIR/venv/bin/activate"
pip install --use-pep517 --no-cache-dir . --extra-index-url https://download.pytorch.org/whl/cu126
fi
# Checks if the git repo has had any changes and updates if needed
echo "Checking if The Git Repo Has Changed...."
git fetch
UPSTREAM=${1:-'@{u}'}
LOCAL=$(git rev-parse @)
REMOTE=$(git rev-parse "$UPSTREAM")
BASE=$(git merge-base @ "$UPSTREAM")
if [ "$LOCAL" = "$REMOTE" ]; then
echo "Local Files Are Up to Date"
elif [ "$LOCAL" = "$BASE" ]; then
echo "Updates Found, Updating the local Files...."
git stash
git config pull.rebase true
git pull
git stash pop
fi
# Gets date modified for upcoming if statements
current=$(date +%s)
last_modified_env=$(stat -c "%Y" "$HOMEDIR/InvokeAI/pyproject.toml")
# Updates Python Environment if changes have been made to the pyproject.toml file
if [ -f "$HOMEDIR/venv/pyvenv.cfg" ] && [ $((current - last_modified_env)) -lt 60 ]; then
echo "Updates Found, Updating Python Environment...."
pip install --use-pep517 --no-cache-dir --upgrade -e .
fi
# Check for changes in the frontend and build if necessary
cd "$HOMEDIR/InvokeAI/invokeai/frontend/web/" || exit
# Get the latest commit hash for the frontend directory
FRONTEND_COMMIT=$(git log -n 1 --pretty=format:"%H" -- .)
# Path to commit hash file
COMMIT_HASH_FILE="$HOMEDIR/userfiles/frontend_commit_hash.txt"
FRONTEND_DIR="$HOMEDIR/InvokeAI/invokeai/frontend/web"
DIST_DIR="$FRONTEND_DIR/dist"
# Get the latest commit hash for the frontend directory
FRONTEND_COMMIT=$(git -C "$HOMEDIR/InvokeAI" log -n 1 --pretty=format:"%H" -- invokeai/frontend/web)
# Function to build frontend
build_frontend() {
echo "Running pnpm install and build..."
cd "$FRONTEND_DIR" || exit
pnpm install
pnpm build
echo "$FRONTEND_COMMIT" > "$COMMIT_HASH_FILE"
cp -r /home/invokeuser/InvokeAI/invokeai/frontend/web/dist \
/home/invokeuser/venv/lib/python3.12/site-packages/invokeai/frontend/web/
}
# Check if build is needed
if [ ! -f "$COMMIT_HASH_FILE" ]; then
echo "No previous frontend build detected. Building the frontend..."
build_frontend
else
PREV_FRONTEND_COMMIT=$(cat "$COMMIT_HASH_FILE")
if [ "$FRONTEND_COMMIT" != "$PREV_FRONTEND_COMMIT" ]; then
echo "Frontend changes detected. Rebuilding the frontend..."
build_frontend
elif [ ! -f "$DIST_DIR/index.html" ]; then
echo "Build output missing. Rebuilding the frontend..."
build_frontend
else
echo "Frontend is up to date. No rebuild necessary."
fi
fi
CONFIG_FILE="$HOMEDIR/userfiles/invokeai.yaml"
LINE_TO_CHECK="host: 0.0.0.0"
mkdir -p "$HOMEDIR/userfiles"
if [ ! -f "$CONFIG_FILE" ]; then
echo "Config file missing. Copying new one..."
cp "$HOMEDIR/invokeai.yaml" "$CONFIG_FILE"
elif ! grep -qF "$LINE_TO_CHECK" "$CONFIG_FILE"; then
echo "Line not found. Overwriting config file..."
cp "$HOMEDIR/invokeai.yaml" "$CONFIG_FILE"
else
echo "Config file already contains the line. No action needed."
fi
# Start the web UI and the backend
echo "Loading InvokeAI WebUI....."
cd "$HOMEDIR/InvokeAI"
python scripts/invokeai-web.py --root="$HOMEDIR/userfiles/"Create a file called invokeai.yaml # Internal metadata - do not edit:
schema_version: 4.0.2
# Put user settings here - see https://invoke-ai.github.io/InvokeAI/configuration/:
host: 0.0.0.0 2. Building the docker image Open the Unraid Terminal cd to folder where the 2 files we just created are stored run this command and wait for it to be done: docker build . -t invokeai_docker_main 3. building the docker container make a file called my-invokeai.xml in \config\plugins\dockerMan\templates-user (on your unraid flash drive) add the text below to it and save then go to your unraid gui and then the docker tab, click "add container", in template dropdown box select your user template "invokeai" change port/host paths if required <?xml version="1.0"?>
<Container version="2">
<Name>InvokeAI</Name>
<Repository>invokeai_docker_main</Repository>
<Registry>https://hub.docker.com/r/mickr777/invokeai_unraid_main</Registry>
<Network>bridge</Network>
<MyIP/>
<Shell>bash</Shell>
<Privileged>false</Privileged>
<Support>https://forums.unraid.net/topic/130913-guide-invokeai-a-stable-diffusion-toolkit-docker/</Support>
<Project>https://github.com/invoke-ai/InvokeAI/</Project>
<Overview>Simplified Docker with auto update for InvokeAI and Unraid.</Overview>
<Category>Other: Status:Beta</Category>
<WebUI>http://[IP]:[PORT:9090]/</WebUI>
<TemplateURL/>
<Icon>https://i.ibb.co/N2c008N/invokeai.png</Icon>
<ExtraParams>--gpus all</ExtraParams>
<PostArgs/>
<CPUset/>
<DateInstalled/>
<DonateText/>
<DonateLink/>
<Requires/>
<Config Name="InvokeAI" Target="/home/invokeuser/InvokeAI/" Default="/mnt/cache/appdata/invokeai/invokeai/" Mode="rw" Description="InvokeAI source code path" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/invokeai/</Config>
<Config Name="userfiles" Target="/home/invokeuser/userfiles/" Default="/mnt/cache/appdata/invokeai/userfiles/" Mode="rw" Description="Persistent storage for models, configs, and outputs" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/userfiles/</Config>
<Config Name="venv" Target="/home/invokeuser/venv/" Default="/mnt/cache/appdata/invokeai/venv/" Mode="rw" Description="Python virtual environment storage" Type="Path" Display="always" Required="true" Mask="false">/mnt/cache/appdata/invokeai/venv/</Config>
<Config Name="cache" Target="/home/invokeuser/.cache" Default="/mnt/user/appdata/invokeai/cache" Mode="rw" Description="Cache directory (e.g., Hugging Face models)" Type="Path" Display="always" Required="true" Mask="false">/mnt/user/appdata/invokeai/cache</Config>
<Config Name="Webui Port" Target="9090" Default="9090" Mode="tcp" Description="WebUI port" Type="Port" Display="always" Required="true" Mask="false">9090</Config>
</Container> 4. Last steps after container build, on first run the python venv will be created once this is done load up any web browser and point it to [Your Unraid IP]:9090 (or the port you set) Last Notes: if you run in to errors after updates, cleaning out the /invokeai/invokeai/ folder and/or deleting the file /invokeai/venv/pyvenv.cfg and rerunning the docker can force a part rebuild and fix a lot of issues Feel free to comment with any suggestions