act icon indicating copy to clipboard operation
act copied to clipboard

On windows, how to clean up after using/uninstall to reclaim/free disk space

Open jigneshsuvariya opened this issue 1 year ago • 4 comments

Details

Hi,

I am using windows 11 and running act for local validation of GitHub actions. I want to thank you this tool really help me lot.

I want to know best and clear steps to how we can do clean up after to reclaim/free disk space. As once those GitHub actions setup done for one of repo it's not needed to update and validate frequently. And right now it's taking big chunk of disk space. C: drive get full 😊.

Following things I already done.

  • Removed images from docker desktop, and restarted it. Freed lot's of space. 👍🏻

Thanks in advance.

jigneshsuvariya avatar Feb 07 '25 11:02 jigneshsuvariya

Once I had to remove the wsl distro of docker to fully reclaim disk space.

Look at act- volumes + containers that may be leaked by act and remove them as well. (planned in https://github.com/actions-oss/act-cli/issues/13 as a sub command)

ChristopherHX avatar Feb 11 '25 20:02 ChristopherHX

Hi there! 👋

Great question about cleaning up disk space after using act on Windows. I've run into this myself and can share some tips that should help!

Docker Resources (the main culprit):

  1. Remove unused containers:

    docker container prune -f
    

    This removes all stopped containers that act creates during runs.

  2. Remove unused images:

    docker image prune -f
    

    Or more aggressively (removes ALL unused images, not just dangling ones):

    docker image prune -a -f
    
  3. Full system cleanup (be careful!):

    docker system prune -f
    

    This removes:

    • All stopped containers
    • All networks not used by at least one container
    • All dangling images
    • All dangling build cache
  4. If you want the nuclear option (removes EVERYTHING including volumes):

    docker system prune -a --volumes -f
    

    ⚠️ Only use this if you're sure you don't need any other Docker data!

Act-Specific Cache:

Act also caches images and actions in these locations:

  • %USERPROFILE%\.act - Contains cached action images
  • %USERPROFILE%\.cache\act - Additional cache directory (if exists)

You can safely delete these folders if you're not planning to use act anymore:

Remove-Item -Recurse -Force ":USERPROFILE\.act"
Remove-Item -Recurse -Force ":USERPROFILE\.cache\act"

Quick Check:

To see how much space Docker is using:

docker system df

This will show you images, containers, volumes, and cache sizes.


Pro tip: If you're using act regularly, consider keeping the larger images (like nektos/act-environments-ubuntu) unless you're really tight on space. They take a while to download but make your workflow runs much faster! 🚀

Hope this helps! Let me know if you have any other questions. 😊

vincent067 avatar Apr 05 '26 01:04 vincent067

This issue has had no activity for 90 days and is now stale. It will be closed in 14 days unless there is new activity.

github-actions[bot] avatar Oct 31 '26 04:10 github-actions[bot]

This issue was closed because it stayed stale for 14 days. Comment or reopen it if it is still relevant.

github-actions[bot] avatar Nov 17 '26 04:11 github-actions[bot]