Skip to main content

Overview

Docker images are managed through the application and service configuration endpoints in Dokploy. When you deploy applications, you can specify Docker images from various sources.

Image Sources

Dokploy supports multiple Docker image sources:
  • Docker Hub - Public and private images
  • GitHub Container Registry (ghcr.io)
  • GitLab Container Registry
  • Custom Registries - Self-hosted or third-party registries

Configuring Image Sources

Docker Image Provider

Set up an application to use a Docker image directly:
dockerImage
string
The full image name including registry, repository, and tag (e.g., nginx:latest, ghcr.io/user/app:v1.0).
username
string
Username for private registry authentication.
password
string
Password or access token for private registry authentication.
registryUrl
string
Custom registry URL if not using Docker Hub.
cURL
curl -X POST "https://your-dokploy-instance.com/api/application.saveDockerProvider" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "applicationId": "app-123",
    "dockerImage": "nginx:latest"
  }'

Database Images

When creating database services, you can specify the Docker image version:

PostgreSQL

dockerImage
string
default:"postgres:18"
The PostgreSQL Docker image to use.
cURL
curl -X POST "https://your-dokploy-instance.com/api/postgres.create" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "My Database",
    "appName": "mydb",
    "environmentId": "env-123",
    "dockerImage": "postgres:16",
    "databaseName": "myapp",
    "databaseUser": "dbuser",
    "databasePassword": "secure_password"
  }'

MySQL

dockerImage
string
default:"mysql:8"
The MySQL Docker image to use.
cURL
curl -X POST "https://your-dokploy-instance.com/api/mysql.create" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "MySQL Database",
    "appName": "mysql-db",
    "environmentId": "env-123",
    "dockerImage": "mysql:8.0",
    "databaseName": "myapp",
    "databaseUser": "dbuser",
    "databasePassword": "secure_password",
    "databaseRootPassword": "root_password"
  }'

MariaDB

dockerImage
string
default:"mariadb:11"
The MariaDB Docker image to use.

MongoDB

dockerImage
string
default:"mongo:8"
The MongoDB Docker image to use.

Redis

dockerImage
string
default:"redis:7"
The Redis Docker image to use.

Build Types

For applications, Dokploy supports multiple build types:
buildType
string
required
The method used to build your application image:
  • dockerfile - Build from a Dockerfile
  • heroku_buildpacks - Use Heroku buildpacks
  • paketo_buildpacks - Use Paketo buildpacks
  • nixpacks - Use Nixpacks for automatic builds
  • static - Serve static files
  • railpack - Build Ruby on Rails applications
cURL
curl -X POST "https://your-dokploy-instance.com/api/application.saveBuildType" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "applicationId": "app-123",
    "buildType": "dockerfile",
    "dockerfile": "Dockerfile",
    "dockerContextPath": "./",
    "dockerBuildStage": "production"
  }'

Registry Management

Manage private Docker registries for pulling and pushing images:
registryId
string
Unique identifier for the registry configuration.
registryUrl
string
The URL of the Docker registry (e.g., ghcr.io, registry.gitlab.com).
username
string
Registry authentication username.
password
string
Registry authentication password or token.

Build docs developers (and LLMs) love