Common Command-Line Options
This page documents common command-line options and concepts shared across copyparty tools.Volume Permissions
Permissions control what users can do within a volume. Specified in volume definitions after the mount path.Permission Flags
permission
Read - List folder contents and download files.
permission
Write - Upload files. Requires
r to see the uploads.permission
Move - Move files and folders. Requires
w at destination.permission
Delete - Permanently delete files and folders.
permission
Get - Download files without seeing folder contents.
permission
Upget - Like
g, but can see filekeys of own uploads.permission
HTML - Like
g, but folders return their index.html.permission
Dots - User can request to show dotfiles in listings.
permission
Admin - View uploader IPs, trigger config reload.
permission
All - Same as
rwmda. (read/write/move/delete/admin/dots).Permission Examples
Volume Flags
Volume flags (volflags) modify volume behavior. Specified after permissions with:c,flag1,flag2.
Upload Flags
volflag
Reject duplicate files during upload.Example:
-v /tmp/inc:/inc:w:c,nodupevolflag
Enable symlink-based upload deduplication.
volflag
Use hardlinks for deduplication (falls back to symlinks).
volflag
How to timestamp uploaded files:
c (client), u (upload-time), fc, fu.volflag
Filename pattern for nameless uploads.Default:
put-{now.6f}-{cip}.binFilesystem Flags
volflag
Unix file permissions (octal) for new files.Example:
chmod_f=644volflag
Unix directory permissions (octal) for new directories.Example:
chmod_d=755volflag
Database durability profile:
acid, swal, wal, yolo.Example: -v ~/music:music:r:c,dbd=swalvolflag
Prevent creating subdirectories.
Display Flags
volflag
Enable the
?dots URL parameter to show hidden files.volflag
Display subdirectory contents in upload page (slow).
volflag
Thumbnail conversion quality/size.
Access Control Flags
volflag
Force authentication for all folders (required by davfs2).
volflag
Who can create shares:
no, a (admin), auth (authenticated).volflag
Who can undo uploads:
0 (none), 1 (same IP+account), 2 (same IP), 3 (same account).Event Hooks
Event hooks execute commands before/after various events. Can be global options or volume flags.Hook Types
hook
Execute command before a file upload starts.Arguments: File path or JSON info
hook
Execute command after a file upload finishes.Arguments: File path or JSON info
hook
Execute command after all uploads finish and volume is idle.Arguments: List of uploaded files (JSON on stdin)Note: Batches multiple uploads, runs once after idle period.
hook
Execute command before a file copy.
hook
Execute command after a file copy.
hook
Execute command before a file rename/move.
hook
Execute command after a file rename/move.
hook
Execute command before a file delete.
hook
Execute command after a file delete.
hook
Execute command when a message is posted.Arguments: Message text or JSON
hook
Execute command when someone gets banned.Return: 0 (true) to cancel the ban
Hook Flags
Prefix hooks with comma-separated flags: Execution:f- Fork process, don’t wait for completionc- Check return code, block action if non-zerow N- Wait N seconds after command startstN- Set N second timeoutiN- (xiu only) Volume idle time in seconds (default 5)I- Import and run as module (140x faster)
j- Provide JSON info as 1st argument instead of filepaths- Provide data on stdin instead of argumentc0- Show all output (default)c1- Show only stderrc2- Show only stdoutc3- Mute all output
ar- Only run if user has read permissionarw- Only run if user has read+writearwmd- Only run if user has all permissions
kt- Kill process tree on timeout (default)km- Kill main process onlykn- Let it run until copyparty terminates
Hook Examples
Authentication Options
Password Hashing
string
default:"none"
Password hashing algorithm:
none- Plaintext (default, not recommended for production)argon2- Argon2id (recommended)scrypt- Scryptsha2- SHA2-512
--ah-alg argon2string
Generate hashed password for the given plaintext.Example:
--ah-gen hunter2IdP / SSO Integration
string
HTTP header containing username from IdP (repeatable).Warning: Ensure clients cannot set this header!Example:
--idp-h-usr Remote-Userstring
HTTP header containing groups from IdP.Example:
--idp-h-grp Remote-Groupsstring
Secret header that must be present to trust IdP headers.Example:
--idp-h-key X-Secret-Keystring
default:"idp,ipu"
Authentication precedence order.Options:
pw (password), idp (identity provider), ipu (IP-based)Examples:pw,idp,ipu- Try password firstipu,idp,pw- IP auth winsidp- Only IdP authentication
IP-Based Authentication
string
Auto-authenticate IPs as specific user (repeatable).Format:
CIDR=USERNAMEExample: --ipu 192.168.1.0/24=alice --ipu 10.0.0.5=bobstring
Restrict user to specific IPs (repeatable).Format:
CIDR1,CIDR2=USERNAMEExample: --ipr 192.168.1.0/24,10.0.0.0/8=aliceDatabase Durability Profiles
Controls how aggressively the database is synced to disk.profile
Extremely safe but slow - Never lose data, even in power loss.Best for: Critical data, single points of failure
profile
2.4x faster, 99.9% as safe - May lose metadata for ~200 recent uploads in power loss.Best for: General use, good balance of speed and safety
profile
21x faster on HDD, 90% as safe - Higher risk of metadata loss.Best for: High-volume uploads, HDD arrays
profile
Fastest, removes upload pauses - Risk of losing entire database.Best for: Temporary data, SSD caching, reproducible uploads
Setting Durability
File Permissions (chmod)
Unix file permission settings for new files and directories.Permission Bits
User, Group, Other digits:0=---(no access)1=--x(execute)2=-w-(write)3=-wx(write + execute)4=r--(read)5=r-x(read + execute)6=rw-(read + write)7=rwx(read + write + execute)
1= Sticky bit2= Setgid4= Setuid
Common Examples
Environment Variables
path
Default config file path (same as
-c).boolean
Disable TLS/SSL support entirely.
boolean
Disable timestamp touching in SFX builds.
Config File Format
Config files use INI-style format with[global] and [volume] sections.
Example Config
Config Sections
[global]- Server-wide settings (maps to--option)[/path]or[path:alias]- Volume definitions- First line specifies permissions
- Following lines are volume flags
Loading Configs
Exit Codes
0- Success1- Error (authentication failed, port in use, etc.)130- Interrupted (Ctrl+C)