Buconos

Run Your Own Private AI Image Generator: A Step-by-Step Guide Using Docker Model Runner and Open WebUI

Published: 2026-05-11 04:03:12 | Category: Cloud Computing

Introduction

Imagine needing a few images for a project, but you're tired of worrying about credit limits, privacy concerns, or overly restrictive content filters that reject your perfectly reasonable request for a dragon wearing a business suit. What if you could generate stunning AI images entirely on your own machine, with no internet dependency and a clean chat interface? That's exactly what Docker Model Runner plus Open WebUI delivers. With just a couple of commands, you can pull a powerful image-generation model, hook it up to a local chat UI, and start creating images in seconds—all fully private, fully local, and completely free from cloud subscriptions.

Run Your Own Private AI Image Generator: A Step-by-Step Guide Using Docker Model Runner and Open WebUI
Source: www.docker.com

Below, we'll walk you through the process step by step. Before you start, make sure you have the prerequisites ready. Ready to build your own private DALL-E? Let's dive in.

What You Need

  • Docker Desktop (macOS) or Docker Engine (Linux)
  • At least 8 GB of free RAM for a small model (more memory is better for faster results)
  • GPU (optional but highly recommended): NVIDIA (CUDA), Apple Silicon (MPS), or a CPU fallback
  • Ability to run docker model version without errors to confirm Docker Model Runner is installed

Step-by-Step Instructions

Step 1: Pull an Image Generation Model

Docker Model Runner uses a modern packaging format called DDUF (Diffusers Unified Format). DDUF bundles all the pieces of a diffusion model—text encoder, VAE, UNet/DiT, and scheduler configuration—into a single portable file. These models are distributed through Docker Hub just like any other container image, making them easy to download and manage.

To pull the default stable diffusion model, open your terminal and run:

docker model pull stable-diffusion

This command downloads a compressed DDUF file (about 6.94 GB for the full model). Once the pull finishes, verify that the model is ready:

docker model inspect stable-diffusion

You should see output similar to the following (truncated for readability):

{
  "id": "sha256:5f60862074a4c585126288d08555e5ad9ef65044bf490ff3a64855fc84d06823",
  "config": {
    "format": "diffusers",
    "size": "6.94GB",
    "diffusers": {
      "dduf_file": "stable-diffusion-xl-base-1.0-FP16.dduf",
      "layout": "dduf"
    }
  }
}

If you see an error, double-check your Docker version and ensure Docker Model Runner is enabled. Once the inspection succeeds, the model is stored locally and ready for inference.

Step 2: Launch Open WebUI

This is where the magic happens. Docker Model Runner includes a built-in command that automatically spins up Open WebUI and connects it to your local model server. Open WebUI is a full-featured chat interface that supports text and image generation, and it's already configured to talk to Docker Model Runner's OpenAI-compatible API—including the /v1/images/generations endpoint.

Run the following command:

docker model launch openwebui

After a few seconds, Docker Model Runner will start the inference backend (using your GPU or CPU) and then launch Open WebUI in a browser tab. If no browser opens automatically, check the terminal output for the local URL (usually http://localhost:3000).

Run Your Own Private AI Image Generator: A Step-by-Step Guide Using Docker Model Runner and Open WebUI
Source: www.docker.com

Behind the scenes, Docker Model Runner acts as a control plane: it manages the model lifecycle, handles requests, and exposes an API that Open WebUI can call directly. All data stays on your machine—nothing is sent to the cloud.

Step 3: Generate Your First Image

Once Open WebUI loads, you'll see a familiar chat interface with a text input. Type a prompt, like "a dragon wearing a business suit, digital art", and hit send. The UI will send your request to the local model, and within seconds, an AI-generated image will appear in the conversation.

You can refine your prompt, try styles, or even request variations. Open WebUI supports multiple images per prompt (adjustable in settings), so you can generate several options at once. All interactions remain completely local and private.

Pro tip: If you want to use a different model, you can pull additional models using docker model pull <model-name> and then select them in Open WebUI's model dropdown.

Tips for Best Results

  • Model size matters: The default stable-diffusion model is 6.94 GB. If you're low on RAM or disk space, look for smaller DDUF models on Docker Hub (e.g., lightweight versions that are 2–3 GB).
  • GPU acceleration is your friend: Running on a CPU will work but will be significantly slower. For smooth performance, use an NVIDIA GPU with CUDA or an Apple Silicon Mac with MPS support.
  • Monitor resource usage: Image generation can spike memory and GPU usage. Keep an eye on your system monitor; if things get sluggish, try reducing the resolution in Open WebUI settings (e.g., 512×512 instead of 1024×1024).
  • Experiment with prompts: The model works best with clear, descriptive prompts. Incorporate stylistic cues like "oil painting", "photorealistic", or "anime" to steer the output.
  • Multiple models: You can pull several models and switch between them in Open WebUI without restarting. Use docker model pull <name> to add more.
  • Keep Docker Model Runner updated: Run docker model version periodically to check for updates that might improve compatibility or performance.

With these steps, you've transformed your local machine into a capable image-generation workstation—no monthly fees, no privacy worries, just pure creative freedom. Enjoy exploring your new private AI studio!