Skip to content

Instantly share code, notes, and snippets.

@sime sime/core.php
Last active Dec 12, 2015

Embed
What would you like to do?
When running CakePHP on Heroku, by default you'll see file permission errors. The Heroku filesystem is read-only, but '/tmp' and '/log' are writable. To remove the errors update Config::config() in core.php
<?php
// Heroku Read-only Filesystem https://devcenter.heroku.com/articles/read-only-filesystem
/**
* Configure the cache used for general framework caching. Path information,
* object listings, and translation cache files are stored with this configuration.
*/
Cache::config('_cake_core_', array(
'engine' => $engine,
'prefix' => $prefix . 'cake_core_',
'path' => '/tmp/', # New Path
'serialize' => ($engine === 'File'),
'duration' => $duration
));
/**
* Configure the cache for model and datasource caches. This cache configuration
* is used to store schema descriptions, and table listings in connections.
*/
Cache::config('_cake_model_', array(
'engine' => $engine,
'prefix' => $prefix . 'cake_model_',
'path' => '/tmp/', # New Path
'serialize' => ($engine === 'File'),
'duration' => $duration
));
@armnosn

This comment has been minimized.

Copy link

armnosn commented Feb 12, 2013

it works. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.