The Dockerfile method of building docker storage i...
# prefect-community
a
The Dockerfile method of building docker storage is leaving tmp directories like
tmp3v36vta4
after registration with cloud. This is cluttering up our repository. Is there a setting to avoid this?
Or to get that folder name so that I can script a cleanup afterwards?
z
Weird, it’s in a context block like
Copy code
with tempfile.TemporaryDirectory(
            dir="." if self.dockerfile else None
        ) as tempdir:
so they should be auto-removed
The
if
statement there is just using the current directory as the base for the temporary directory if you’re using a custom dockerfile.
The
TemporaryDirectory
context should be quite robust ensuring deletion on failures
Does the directory remain every time you build storage?
a
Could be a relic of running
docker build()
outside of prefect. I'll report back if that is not the case