Move creation of log and cache to after creation of app folder