Configuration File (presets.yaml)
Presets are defined in a YAML file named presets.yaml. mkbrr searches for this file in the following locations, using the first one it finds:
Path specified by the --preset-file flag (if used)
The current working directory (./presets.yaml)
~/.config/mkbrr/presets.yaml (or equivalent user config directory)
~/.mkbrr/presets.yaml (legacy location)
Structure
The presets.yaml file follows this structure:
presets.yaml
presets.yaml (minimal example)
# yaml-language-server: $schema=https://raw.githubusercontent.com/autobrr/mkbrr/main/schema/presets.json
version : 1
# Optional: Default settings applied to ALL presets unless overridden
default :
private : true
no_date : true
no_creator : false
skip_prefix : false
# comment: "Default comment"
# source: "DEFAULT_SRC"
# exclude_patterns: ["*.bak", "temp.*"]
# include_patterns: ["*.mkv", "*.mp4"]
presets :
preset-name-1 : # Name of the preset (used with -P flag)
trackers :
- "https://tracker-one.com/announce/..."
source : "TRACKER1"
comment : "Uploaded via mkbrr"
private : true
exclude_patterns :
- "*.nfo"
- "*sample*"
preset-name-2 :
trackers :
- "udp://tracker-two.org:6969/announce"
private : false # Make these torrents public
piece_length : 18 # Use 256 KiB pieces for this preset
include_patterns :
- "*.mkv"
- "*.mp4"
- "*.avi"
Optional settings applied to all presets unless explicitly overridden within a specific preset
A map where each key is the preset name (e.g., ptp, public) and the value contains the options for that preset
Available Options
The following options can be used within the default section or any specific preset:
Core Options
Piece Settings
File Control
Advanced
List of announce URLs. The first one is used as the primary tracker.
Whether the torrent should be private.
Piece size exponent (e.g., 18 for 256 KiB).
Maximum piece size exponent for automatic calculation.
List of glob patterns to exclude files.
List of glob patterns to include files (takes precedence over exclude).
Whether to prevent adding the tracker domain prefix to the output filename.
Manually specify the number of concurrent goroutines used for hashing. Experimenting with different values might yield better performance than the default automatic setting.
Whether to randomize the torrent’s info hash by adding a unique, random key to the info dictionary. Useful for cross-seeding identical content on trackers that reject duplicate info hashes.
Whether to omit creation date.
Whether to omit creator string.
You can find the formal JSON schema for validation here .
Using Presets
Specify the preset name using the -P (or --preset) flag with the create or modify commands:
mkbrr create /path/to/content -P preset-name-1
Overriding Presets
Command-line flags take precedence over preset settings. Most flags completely override their preset counterparts, but filtering options have special behavior:
Filtering patterns are additive : Command-line patterns combine with preset patterns
Example: Combining Preset and Command-line Filters
presets :
movies :
include_patterns :
- "*.mkv"
- "*.mp4"
exclude_patterns :
- "*sample*"
Command with Additional Filters
# This combines the preset patterns with command-line patterns
mkbrr create /path/to/content -P movies --include "*.srt" --exclude "*.nfo"
# Effective filters applied:
# include_patterns: ["*.mkv", "*.mp4", "*.srt"]
# exclude_patterns: ["*sample*", "*.nfo"]
Standard command-line flags (like --private or --source) completely override their preset values, while filtering patterns combine additively.
Override source flag
Override private flag
mkbrr create /path/to/content -P preset-name-1 -s "CUSTOM_SRC"