yiiext/cachecleaner

simple yii cache cleaner module

0.0.2 2014-07-22 15:37 UTC

README

Simple module for clear yii apache cache and doing some tasks before it

Config:

    
// protected/config/console.php
return array(
    ...
    'commandMap'=>array(
        'cache' => array(
            'class' => 'application.vendors.yiiext.cachecleaner.commands.CacheCommand',
            'cleanAssets'=> true, // if its false it wont clean project assets folder
            'extraCommands'=> array(), // multiple bash commands like array('yiic migrate up','yiic shell')
            'pingMethod'=>'wget', // wget, curl
            'interactive'=>true,  //no confirm message
            'pingProjectPath'=>'/', //project path exp: http://127.0.0.1/{pingprojectpath}/cachecleaner
        ),
    ),
);
    
    
// protected/config/main.php
return array(
    ...
    'modules' =>array(
        'cachecleaner' =>array(
            'class' => 'application.vendors.yiiext.cachecleaner.CachecleanerModule',
            'trustedIpList'=>array('127.0.0.1'),
        ),
        ...
    ),
    'components' => array(
        'cache'=>array(
            'class'=>'CApcCache',
        ),
        ...
     )
);