WebUI Guide - ffxvs/sd-webui-complete-setup GitHub Wiki

[!NOTE] This guide is for Auto1111/Forge WebUI on Paperspace and RunPod

Table of Contents

  1. Requirements
    1.1. Initialization
    1.2. WebUI Settings
    1.3. Temporary Storage Settings (Paperspace Only)
  2. WebUI Extensions
  3. Launch WebUI

Tips

[!TIP]

  • Use the triangle arrow button to the left of the cell title to show/hide the cell contents to make scrolling easier.
  • Use the Table of Contents in the left sidebar for easier navigation.
  • You can open the links provided for each model name, extension, or other resources to see more details.
  • Run cell with the play button in the toolbar or hotkey shift+enter.
  • Wait for the cell to finish executing until the Completed message in green box appears in the output.
  • Clear the output with Clear Cell Outputs or Clear Outputs of All Cells in the right click context menu.
  • To download images you generated, right click on the outputs folder then click Download as an Archive.

Change the value of options

When using this notebook you will often encounter several types of options whose values can be changed.

  • option = []
    Fill the bracket with strings enclosed in single quotation marks ', separated by commas ,
    Example :
other_extensions = [  
     'https://github.com/Bing-su/adetailer',  
     'https://github.com/continue-revolution/sd-webui-animatediff'  
]  
# Install Adetailer and AnimateDiff extensions

  • option = ''
    Write string inside the single quotation marks ' '
    Example :
webUI.username = 'user'
webUI.password = 'password'

Updating

To help you understand how the update process works, this project consists of :

  1. Container, contains the main dependencies to run Stable Diffusion, such as python, pytorch, xformers, cuda, jupyter lab, etc. For RunPod, the container will be updated automatically. While in Paperspace, because Paperspace caches the old container in their server, you have to create a new installation with specific container version. Which means that when there is a new version of the container, you have to update it manually by creating a new installation again. For more details.
  2. Notebooks, to install/update WebUI and download the necessary resources. Notebooks will be updated automatically every time you start the machine. When there is a new version, your old notebook will be move to old-notebooks directory.
  3. WebUI, it will be updated every time you run cell 1.1. Initialization in notebook setup.
  4. Assets, consists of modules for running notebooks and resource lists when you want to download models and others. Assets are also updated automatically when you start the machine.

1. Requirements

1.1. Initialization

Required every time you start the machine/pod or more precisely when the kernel starts running. If the kernel is shut down or restarted, then this cell must be executed again. This cell will update dependencies, create shared storage, install or update WebUI and download config files.

1.2. WebUI Settings

Manage API Keys, ngrok, custom configs and other settings.

  • CivitAI API Key
    Some models hosted by CivitAI require you to login to download. Create an API key in CivitAI user settings.
  • HuggingFace Token
    If you want to download models from private repository in HuggingFace, you need access token. Create a token in HuggingFace settings.
  • Ngrok token and domain
    Proxy for stable connection and static url. One of the advantages of having a static url is that you can use State extensions properly because the parameters are stored in the subdomain that do not change. Register at ngrok, then get your authtoken and create a free domain.

[!CAUTION] Some users reported that using ngrok on Paperspace can get you banned. I don't recommend using ngrok on Paperspace. But, if you want to take the risk or have never had problems with ngrok before, go ahead.

  • Custom configs
    Use your own config.json and ui-config.json and update them independently. The easiest way is to create a repo in GitHub then upload the configs there. After downloading the configs, don't forget to click the save button, otherwise the urls you input will be lost.
  • Auto Update Forge
    Enable or disable the automatic update of Forge. Forge doesn't use tag versioning and updates can come daily. But an update could break something, so this setting might be useful. Default : enabled.
  • Enable Dark Theme
    Enable dark theme for WebUI. Default : enabled.

1.3. Temporary Storage Settings (Paperspace Only)

Store your models, LoRA, controlNet and text encoder in temporary storage. Settings will persist even if you restart the machine. Paperspace's Pro give you 15GB of free storage. More than that, you will be charge $0.29/GB/month. To avoid that, you can use this feature to store some resources in the temporary storage. You can easily switch between shared storage and temporary storage. But when switching storage, all files in the selected directories will be deleted and you need to download them again.

2. WebUI Extensions

Extensions

You can choose any extensions you want to install before launching WebUI. There are built-in extensions that will be installed automatically and several popular extensions that may be useful for you. As for Forge, some extensions might not work properly. If you find any extension error, please report it to me.

Install Extensions from URLs

You can install other extensions yourself by copying the github repository URL into bracket of other_extensions.

  • update_exts
    If you want to update the extensions in the bracket, change this option to True.

Example :

other_extensions = ['https://github.com/Bing-su/adetailer']
# or
other_extensions = [
    'https://github.com/Bing-su/adetailer',
    'https://github.com/continue-revolution/sd-webui-animatediff'
]

3. Launch WebUI

  • Authentication
    When you launch a Web UI on the internet, anyone can access it freely which can be harmful. It's recommended to enable authentication for security reasons.
webUI.username = 'your_username'
webUI.password = 'your_password'
  • CORS (optional)
    To bypass CORS policy. Write URLs with https:// inside cors. Separate them with commas.
    Example :
webUI.cors = 'https://huchenlei.github.io,https://ffxvs.github.io'