I'm using side services through docker that I run before launching serverless offline, however for my colleagues I inline it with docker-compose up -d && serverless offline. Issue is, I would like to docker-compose down when serverless offline is stopped. It looks like the --exec option is not handled anymore. I've also tried using trap 'command' EXIT & serverless offline but command is then executed at the beginning as serverless offline already works around it. Any idea how to do it?
I'm using side services through docker that I run before launching
serverless offline
, however for my colleagues I inline it withdocker-compose up -d && serverless offline
. Issue is, I would like todocker-compose down
whenserverless offline
is stopped. It looks like the--exec
option is not handled anymore. I've also tried usingtrap 'command' EXIT & serverless offline
butcommand
is then executed at the beginning as serverless offline already works around it. Any idea how to do it?