miniature-apartment-8295
11/01/2023, 11:08 AMpython_tests(
environment="test_docker_environment",
)
and in the parent folder the environment is defined
docker_environment(
name="local_test_environment",
image="image_sha",
)
and in my pants.toml I have added
[environments-preview.names]
test_docker_environment = "//parent/folder:local_test_environment"
local = "//:local-environment"
This all works fine and using pants test ::
the test runs successfully in its own docker container.
However, the container remains after the tests and is not removed. This is not a big problem but still a little annoying. Is there a way to change this behaviour and tell pants to clean up all containers that have been startet in tests?
Edit: Fixed some typos in the environment names.miniature-apartment-8295
11/06/2023, 10:46 AMcurved-television-6568
11/06/2023, 2:51 PMminiature-apartment-8295
11/07/2023, 1:40 PMcurved-television-6568
11/07/2023, 3:20 PMwitty-crayon-22786
11/07/2023, 5:45 PMpantsd
restarts cleanly. if pantsd
restarts uncleanly (due to kill -9
for example) then they may be orphanedwitty-crayon-22786
11/07/2023, 5:46 PMminiature-apartment-8295
11/10/2023, 3:45 PM