I'm running a docker computer, more specifically a docker-compose setup, on a very expensive machine. Ideally, if my docker compose exits, I'd like to run a cleanup action (e.g an rsync), and then shutoff the machine.
My first pass at this will probably be a shell script, but I was wondering if there was a more robust way to do this.