Skip to content

Instantly share code, notes, and snippets.

@jepster
Created December 18, 2014 17:55
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save jepster/591e87cc771d52b98d41 to your computer and use it in GitHub Desktop.
Save jepster/591e87cc771d52b98d41 to your computer and use it in GitHub Desktop.
yii_boot_console.inc.php
<?php
defined('YII_DEBUG') or define('YII_DEBUG', true);
// fcgi doesn't have STDIN and STDOUT defined by default
defined('STDIN') or define('STDIN', fopen('php://stdin', 'r'));
defined('STDOUT') or define('STDOUT', fopen('php://stdout', 'w'));
require_once(__DIR__ . '/vendor/autoload.php');
require_once(__DIR__ . '/vendor/yiisoft/yii2/Yii.php');
use app\controllers\CmPlatformDeterminationClass;
defined('ENVIRONMENT') or define('ENVIRONMENT', 'dev');
if(!isset($argv)){
$argv = false;
}
// the path to your config file.
$config = require_once('the/path/to/your/config/file.php');
new yii\console\Application($config);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment