Note the upgraded forum! If you are experiencing issues logging in, you may need to reset your password which should send an email. If the email doesn't arrive, be sure to check your spam folder just in case.

Asset cache folder location

edited January 2017 in Share
I have the same codebase on a server in production and development environments.

I moved recent dev code to production OK, but the asset cache couldn't be used in the same way it was on dev. Usually, the production & dev code uses the "combine" asset setting. But on production the cache files for js and css were not being written.

I upped the log level and found this:
ERROR - 2017-01-15 10:30:36 --> Severity: Warning --> opendir(/home/xxx/public_html/assets/cache/cache/): failed to open dir: No such file or directory ...

So I commented out the cache key in
$config['assets_folders'] = array( ... ... 'cache' => 'cache/' // removed );
and then the asset cache files were able to be generated again in /assets/cache. But I feel uneasy that this doesn't really address the problem, and that this may bite me later.

Why would the cache folder be (incorrectly) nested as per the opendir log entry?

Comments

  • edited January 2017
    In other environments however, removing the cache key from assets_folders results in the cache file being located in the assets root. So now I'm doing this...
    // odd we have to do this... if(ENVIRONMENT !== 'production') { $config['assets_folders']['cache'] = 'cache/'; }

    What is this further asset config for?
    // cache folder relative to the web root folder... must be writable directory (default is the application/assets/cache folder) $config['assets_cache_folder'] = 'cache/';

    In the latest Fuel (v1.3.2) this has no trailing slash. But the comment suggest it is set in the application folder in any case??
  • edited 5:11AM
    That comment is incorrect. It's actually just the assets/cache/ folder. What version are you using in production?
  • edited 5:11AM
    I've just updated to the latest.
Sign In or Register to comment.