Skip to main content

Overview

While Miku Miku Beam doesn’t include a pre-built Dockerfile in the repository, it’s designed to be Docker-ready and can be easily containerized for deployment. This guide will walk you through creating and deploying MMB in a Docker container.

Creating a Dockerfile

Multi-stage Dockerfile

Create a Dockerfile in the project root with the following content:

Docker Compose Setup

Create a docker-compose.yml file for easier deployment:

Building the Image

1

Build with Docker

Build the Docker image directly:
2

Or build with Docker Compose

Build using Docker Compose:

Configuration Files

Before running the container, prepare the required configuration files:
1

Create data directory

2

Create proxies.txt

Add your proxy list (one per line):
Proxy format supports:
  • protocol://user:password@host:port (with authentication)
  • protocol://host:port
  • host:port (defaults to HTTP)
  • host (defaults to port 8080)
3

Create uas.txt

Add user agent strings (one per line):
4

Create config.toml (optional)

Override default configuration:

Running the Container

Using Docker Run

Using Docker Compose

Environment Variables

string
default:"console"
Log output format. Set to json for structured logging in production
boolean
default:"false"
Allow running attacks without proxies. Set to true to enable

Volume Mounts

Port Mappings

Health Checks

Add a health check to your Dockerfile:
Or in docker-compose.yml:

Docker CLI Access

You can also run attacks using the CLI tool inside the container:

Production Optimization

Troubleshooting

Check if the web client was built correctly:
If empty, rebuild the image ensuring the web-client build stage completes successfully.
Ensure the data volume is mounted correctly and contains proxies.txt:
Or run with ALLOW_NO_PROXY=true to disable proxy requirement.
If using the non-root user setup, ensure proper permissions:

Next Steps

Production Deployment

Learn how to deploy MMB in production environments

Configuration

Configure server settings and parameters