Run TRIM on Windows every 15m

As the Windows virtual device supports TRIM we can run this to free
up disk space frequently. Not recommended to run on physical devices
this often.

See https://github.com/docker/pinata/issues/5298

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
This commit is contained in:
Justin Cormack 2016-11-23 11:30:35 +00:00
parent 9f45664f6f
commit 3dc7419954

4
alpine/etc/periodic/15m/trim Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
# Windows always has TRIM support, clean out unused frequently
[ "$(mobyplatform)" = "windows" ] && /sbin/fstrim /var