Skip to content

Complete Guide: Installing Open WebUI with Docker

This comprehensive guide walks you through the process of installing and configuring Open WebUI using Docker containers. Learn how to set up the pipeline service, configure Nginx as a reverse proxy, and integrate Google's AI capabilities.

Prerequisites

Before starting the installation, ensure you have:

  • Docker installed and running on your system
  • Basic understanding of terminal commands
  • Nginx (optional, for reverse proxy setup)
  • Sufficient disk space for Docker containers

Directory Structure Setup

First, we'll create the necessary directory structure to store Open WebUI data:

  1. Create the main data directory:

    Bash
    mkdir -p ~/open-webui/data
    

  2. Create the Open WebUI application data directory:

    Bash
    mkdir ~/open-webui/data/open-webui
    

  3. Create the pipelines data directory:

    Bash
    mkdir ~/open-webui/data/pipelines
    

Docker Container Setup

1. Launch Pipeline Service

Deploy the pipeline service container with persistent storage:

Bash
docker run -d -v "~/open-webui/data/pipelines":/app/pipelines --name pipelines --restart always  ghcr.io/open-webui/pipelines:main

2. Deploy Open WebUI Container

Start the main Open WebUI application:

Bash
docker run -d -p 3000:8080  -v "~/open-webui/data/open-webui":/app/backend/data --name open-webui --restart always  ghcr.io/open-webui/open-webui:main 

Advanced Configuration

Nginx Reverse Proxy Setup (Optional)

For production deployments, you can configure Nginx as a reverse proxy:

  1. Create a new Nginx configuration file:

    Bash
    sudo nano /etc/nginx/site-avaliable/open-webui
    

  2. Add the following configuration:

    Nginx Configuration File
    server {
        listen 127.0.0.1:9443 ssl http2;
        server_name <domain>;
    
        ssl_certificate         /etc/ssl/<domain>/crt.pem;
        ssl_certificate_key     /etc/ssl/<domain>/key.pem;
        ssl_client_certificate  /etc/ssl/<domain>/cloudflare-ca.pem;
        ssl_verify_client on;
    
        ssl_protocols TLSv1.2 TLSv1.3;
    
        location / {
            proxy_pass http://localhost:3000;
            # WebSocket support configuration
            proxy_http_version 1.1;
            proxy_set_header Upgrade $http_upgrade;
            proxy_set_header Connection "upgrade";
    
            # Standard proxy headers
            proxy_set_header Host $host;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
            proxy_set_header X-Forwarded-Proto $scheme;
    
            # Connection timeouts
            proxy_read_timeout 60s;
            proxy_send_timeout 60s;
        }
    }
    

  3. Enable the configuration:

    Bash
    ln -s /etc/nginx/site-avaliable/open-webui /etc/nginx/site-enabled/open-webui
    

Initial Configuration

Basic Setup

  1. Access the web interface:
  2. Local installation: http://localhost:3000
  3. Domain setup: https://<domain>
  4. Complete the initial user setup by creating admin credentials

Pipeline Connection

  1. Navigate to User -> Settings -> Connections
  2. Configure the pipeline service:
  3. Add connection URL: http://<pipeline docker ip address>:9099
  4. Save the configuration

Google AI Integration

Enhance your Open WebUI with Google's AI capabilities:

  1. Access User -> Settings -> Pipelines
  2. Install the Google pipeline:
  3. Source URL: https://github.com/open-webui/pipelines/blob/main/examples/pipelines/providers/google_manifold_pipeline.py
  4. Configure your Google Gemini API key
  5. Access Google AI models in the chat interface

Troubleshooting

If you encounter issues: - Verify Docker container status using docker ps - Check container logs with docker logs open-webui or docker logs pipelines - Ensure all required ports are accessible - Verify file permissions in the data directories

For more information and updates, visit the official Open WebUI repository.