Setting up permissions for cache and logs