compose-watcher
Project description
compose-watcher
Cli that restarts you docker compose services when a file inside one of its volumes changes
To use with compiled languages place the compilation step in the command
field.
Example usage
- graphql api restart when schema file changes
- Mongoke restarts when config schema changes
- Nodejs container restarts when the src folder changes, recompiling with tsc
Install
pip3 install compose-watcher
Usage
Use the directories you want to track as service volumes
version: '3'
services:
api:
build: node_api
command: sh -c 'tsc --incremental && node index.js'
volumes:
- ./node_api/src:/src
Then execute compose-watcher
to watch changes
compose-watcher -f docker-compose.yml --timeout 5
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
compose-watcher-1.0.2.tar.gz
(4.0 kB
view hashes)