Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can mounts be removed from kill? #209

Open
mccalluc opened this issue Oct 3, 2018 · 0 comments
Open

Can mounts be removed from kill? #209

mccalluc opened this issue Oct 3, 2018 · 0 comments

Comments

@mccalluc
Copy link
Member

mccalluc commented Oct 3, 2018

docker_utils.py:

    def kill(container):
        mounts = container.attrs['Mounts']
        container.remove(
            force=True,
            v=True  # Remove volumes associated with the container
        )
        for mount in mounts:
            source = mount['Source']
            target = source if os.path.isdir(
                source) else os.path.dirname(source)
            rmtree(
                target,
                ignore_errors=True
            )

We shouldn't have local mounts any longer, so can I get of those parts of the code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant