Skip to content

DockSprout is a lightweight CLI tool that automatically discovers and starts Docker Compose projects from a central directory. It recursively searches subdirectories for docker-compose.yml files and brings up containers, simplifying the management of multiple services with a single command.

License

Notifications You must be signed in to change notification settings

Thompson-Jason/DockSprout

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DockSprout

A simple CLI tool to bring up Docker containers from multiple docker-compose.yml files in subdirectories.


Features

  • Scans a central directory for docker-compose.yml files.
  • Recursively searches subdirectories for Docker Compose projects.
  • Automatically brings up (or down) all discovered containers using docker compose.
  • Use a .sprout-ignorefile to ignore certain directories of containers you don't want brought up.
  • A lightweight and convenient automation tool for managing multiple Docker services.

🛠 Installation

  1. Install Rust toolchain https://www.rust-lang.org/tools/install
  2. Run cargo install dock_sprout

Homebrew

brew install Thompson-Jason/tap/dock_sprout

Build from Source

git clone https://github.com/Thompson-Jason/DockSprout.git
cd DockSprout
cargo build --release

Usage

Basic Usage

sprout <root-directory> <docker-compose-direction>

Options

  • --concurrent : Run all docker compose commands in parallel (faster for many projects)
  • --verbose : Output docker compose logs to stdout/stderr

Examples

Bring up all containers, sequentially:

sprout ~/my-docker-projects up

Bring up all containers concurrently:

sprout --concurrent ~/my-docker-projects up

Bring up all containers and show all output:

sprout --verbose ~/my-docker-projects up

Bring down all containers concurrently and show output:

sprout --concurrent --verbose ~/my-docker-projects down
─── my-docker-projects
    ├── LubeLogger/
    │   └── docker-compose.yml
    ├── ntfy/
    │   └── docker-compose.yaml
    ├── Portainer/
    │    ├── docker-compose.yaml
    │    └──.conf
    └── .sprout-ignore

This will bring up all three containers separately allowing for the esability of one command to bring all of your containers up and none of the downsides of a mono compose file.

About

DockSprout is a lightweight CLI tool that automatically discovers and starts Docker Compose projects from a central directory. It recursively searches subdirectories for docker-compose.yml files and brings up containers, simplifying the management of multiple services with a single command.

Resources

License

Stars

Watchers

Forks

Contributors 2

  •  
  •  

Languages