Skip to content

Docker Deployment

Docker deployment is suitable for users with their own servers, providing more control and customization capabilities.

🚀 Quick Deployment

  1. Create Project Directory
bash
mkdir cloudflare-imgbed
cd cloudflare-imgbed
  1. Download Docker Compose File
bash
# Download docker-compose.yml
wget https://raw.githubusercontent.com/MarSeventh/CloudFlare-ImgBed/main/docker-compose.yml

# Or manually create
curl -o docker-compose.yml https://raw.githubusercontent.com/MarSeventh/CloudFlare-ImgBed/main/docker-compose.yml
  1. Create Configuration File

Create wrangler.toml file:

toml
name = "cloudflare-imgbed"
compatibility_date = "2024-07-24"

# Optional: Add environment variables, most configurations have been migrated to admin backend after v2.0
# [vars]
  1. Start Service
bash
# Start service (run in background)
docker compose up -d

# View logs
docker compose logs -f
  1. Access Service

Open browser and visit: http://your-server-ip:7658

Method 2: Docker Command

  1. Create Project Directory
bash
mkdir cloudflare-imgbed
cd cloudflare-imgbed
  1. Create Configuration File

Create wrangler.toml file:

toml
name = "cloudflare-imgbed"
compatibility_date = "2024-07-24"

# Optional: Add environment variables, most configurations have been migrated to admin backend after v2.0
# [vars]
  1. Pull Image
bash
docker pull marseventh/cloudflare-imgbed:latest
  1. Run Container
bash
docker run -d \\
  --name cloudflare-imgbed \\
  -p 7658:8080 \\
  -v $(pwd)/data:/app/data \\
  -v $(pwd)/wrangler.toml:/app/wrangler.toml \\
  marseventh/cloudflare-imgbed:latest
  1. Access Service

Open browser and visit: http://your-server-ip:7658

⚙️ Configuration Guide

Volume Mount Description

PathDescriptionRequired
./data:/app/dataData persistence directoryYes
./wrangler.toml:/app/wrangler.tomlConfiguration fileYes

🚀 Next Steps

At this point, the project has been deployed via Docker, with default support for Cloudflare R2 storage channel. For adding other storage channels and other settings, please refer to Configuration Guide.

Released under the MIT License