Skip to main content

A smart CLI wrapper for docker compose with interactive selection support.

Project description

Fast DCP

🚀 A smart CLI wrapper for docker compose — with interactive file, profile, and service selection.

🆕 Highlights

Interactive file, profile & service selection

Running -f, -pf, or -s without arguments auto-detects compose files, profiles, and services, letting you choose interactively.

$ dcpu -f
☑ Found 2 docker-compose files!
    1. docker-compose.yml
    2. docker-compose.prod.yml
Enter your choices (e.g., 1,3,4) or 'q' to quit:

$ dcpu -pf
☑ Found 2 profiles!
    1. dev
    2. prod
Enter your choices (e.g., 1,3,4) or 'q' to quit:

$ dcpu -s
☑ Found 3 services!
    1. db
    2. frontend
    3. app
Enter your choices (e.g., 1,3,4) or 'q' to quit:

Sample Usage

# docker compose up --build
dcpu -b
# docker compose exec app bash
dcpe app
# Auto-detects that `pytest` is not a service name, then prompts interactive selection
dcpe pytest
# docker compose restart app
dcp re app

For more examples, see the List of Commands section below.

Install fast-dcp

Quick Install

# Using pipx
pipx install fast-dcp
# OR using uv
uv tool install fast-dcp

Not familiar with Python tooling?

If you don't have pipx or uv installed yet:

Windows
python -m pip install --user pipx
python -m pipx ensurepath
# Restart terminal, then:
pipx install fast-dcp
macOS
brew install pipx
pipx ensurepath
pipx install fast-dcp
Linux (Ubuntu/Debian)
pip install pipx
pipx ensurepath
pipx install fast-dcp

Features

  • Interactive Selection: auto-detect and interactively select compose files, profiles, and services
  • Short Aliases: dcp u, dcp b, dcp e — fewer keystrokes for common commands
  • Dedicated Commands: dcpu and dcpe for frequent up/exec workflows
  • Zero Config: No configuration files needed — just install and run
  • Cross-Platform: Works on Windows, macOS, and Linux

FAQ

Why use pipx or uv tool instead of pip?

Both pipx and uv tool install CLI tools in isolated environments, so fast-dcp won't conflict with other Python packages. The commands (dcp, dcpu, dcpe) are available globally without activating a virtual environment. uv tool is the faster alternative if you already use uv.

Requirements

  • Python 3.11+
  • Docker with Compose V2 (docker compose — not docker-compose)
  • A docker-compose.yml (or *compose*.yml/yaml) in the current directory for interactive selection features

List of Commands

Common options (available for all commands): -s, -f FILE..., -pf PROFILE..., -p PROJECT

⚠️ Note: -f, -pf, -p are passed before the subcommand in the actual docker compose syntax,
but in fast-dcp they are specified after the subcommand (e.g. dcp up -f FILE).

Bash Command Executed Docker Command
dcp - (Show help)
dcpu [SERVICE...] [-d] [-b] [-w] docker compose up [SERVICE...]
dcpe [SERVICE] docker compose exec SERVICE bash
dcpe [SERVICE] [COMMANDS...] docker compose exec SERVICE [COMMANDS...]
dcp up(u) [SERVICE...] docker compose up [SERVICE...]
dcp up(u) -d docker compose up -d
dcp up(u) -b docker compose up --build
dcp up(u) -w docker compose up --wait
dcp build(b) [SERVICE...] docker compose build [SERVICE...]
dcp exec(e) [SERVICE] docker compose exec SERVICE bash
dcp exec(e) [SERVICE] [COMMANDS...] docker compose exec SERVICE [COMMANDS...]
dcp run [SERVICE] docker compose run SERVICE bash
dcp restart(re) [SERVICE...] docker compose restart [SERVICE...]
dcp ps [SERVICE...] [-a] [-st STATUS] docker compose ps [SERVICE...] [--all] [--status ...]
dcp logs(l) [SERVICE...] [-fo] docker compose logs [SERVICE...] [-f]
dcp stop(s) [SERVICE...] docker compose stop [SERVICE...]
dcp down [-ro] docker compose down [--remove-orphans]

and more... see dcp --help for the full list of supported commands and options.

License

MIT LICENSE

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fast_dcp-0.5.3.tar.gz (17.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fast_dcp-0.5.3-py3-none-any.whl (10.1 kB view details)

Uploaded Python 3

File details

Details for the file fast_dcp-0.5.3.tar.gz.

File metadata

  • Download URL: fast_dcp-0.5.3.tar.gz
  • Upload date:
  • Size: 17.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for fast_dcp-0.5.3.tar.gz
Algorithm Hash digest
SHA256 5d837641fb8aa2989536366cb67cd1336247176f0bcff330bf1c71d392c290d2
MD5 f34b2c64236a451b6b6d1031578d473a
BLAKE2b-256 57d9024bf2cf29e0718f18368df654896e0ac17d8b5845e15de6e2d1b09cb0b1

See more details on using hashes here.

File details

Details for the file fast_dcp-0.5.3-py3-none-any.whl.

File metadata

  • Download URL: fast_dcp-0.5.3-py3-none-any.whl
  • Upload date:
  • Size: 10.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for fast_dcp-0.5.3-py3-none-any.whl
Algorithm Hash digest
SHA256 362386a1ec977e9accf01433c42c5934ea0f34c4a0abe804a20d70a4a8641379
MD5 af21918f279fd9cb6ef582686046cbc7
BLAKE2b-256 28ed3dc28b61480ffeec4eaf69b9fc0bd88116bfd2d6ad17583f4b05523582ea

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page