Split tasks out into files, added clear cache task
Ensure media dir has correct perms