Offline Deployment
For offline environments, Dify can be deployed using either of the following two methods:
- Set up a domain whitelist in your network configuration to allow access to necessary domains, or
- Follow the steps below to achieve a completely network-isolated deployment.
Disable Marketplace Access
By disabling the marketplace connection, you can prevent issues caused by failed external requests:
marketplace:
enabled: false # Disable marketplace access
url: "https://marketplace.dify.ai"
apiUrl: "https://marketplace.dify.ai"
If your network cannot access docker.io
, you can use a custom image repository to replace the default image addresses.
plugin_connector:
gatewayImage: "nginx:1.27.3"
shaderImage: "gcr.io/kaniko-project/executor:latest"
busyBoxImage: "busybox:latest"
awsCliImage: "amazon/aws-cli:latest"
generatorConf: |
generator:
repo: langgenius
python:
pipMirror: ""
preCompile: true
versions:
python3.13:
langgenius: docker.io/langgenius/plugin-build-base-python:3.13
python3.12:
langgenius: docker.io/langgenius/plugin-build-base-python:3.12
python3.11:
langgenius: docker.io/langgenius/plugin-build-base-python:3.11
python3.10:
langgenius: docker.io/langgenius/plugin-build-base-python:3.10
- The following images need to be replaced with private images:
gatewayImage
: Plugin gateway service image.
shaderImage
: Shader image used during plugin build.
busyBoxImage
: Busybox image used during plugin runtime.
awsCliImage
: AWS CLI tool image. If AWS is not used, this image can be ignored.
python3.xx
: Base image for building plugins.
-
Replace pipMirror
with your custom mirror source URL.
-
Sync the images to your private image repository.
Responses are generated using AI and may contain mistakes.