When you `pants run` a docker image target with `r...
# general
When you
pants run
a docker image target with
, the created container doesn't get stopped if some source files changed. a build is triggered and a new container is created and run but the old one keeps running. Is that intended behaviour?
that doesn’t sound right, but, pants makes no assumptions about how you want to run your container (even in the face of
), so you may want to add
-it --rm
to your docker run args
I added --rm but it only removes if stopped manually with ctrl-c, not with a restart
I added the --rm in pants.toml:
Copy code
run_args = "--rm"
Yeah, this is a bug. The restartable concept is Pants engine node level and it appears to have no notion of killing the prior generation node run.