-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29 from yii2mod/add_environments
Add environments
- Loading branch information
Showing
32 changed files
with
555 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
common-local.php | ||
main-local.php | ||
console-local.php | ||
params-local.php | ||
test_db.php | ||
test.php |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,11 @@ | |
|
||
Yii::setAlias('@tests', dirname(__DIR__) . '/tests'); | ||
|
||
$params = array_merge( | ||
require(__DIR__ . '/params.php'), | ||
require(__DIR__ . '/params-local.php') | ||
); | ||
|
||
$config = [ | ||
'name' => 'Yii2 Basic Template', | ||
'language' => 'en-US', | ||
|
@@ -42,10 +47,7 @@ | |
], | ||
], | ||
], | ||
'params' => [ | ||
'adminEmail' => '[email protected]', | ||
'user.passwordResetTokenExpire' => 3600, | ||
], | ||
'params' => $params, | ||
]; | ||
|
||
return $config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<?php | ||
|
||
return [ | ||
'adminEmail' => '[email protected]', | ||
'user.passwordResetTokenExpire' => 3600, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,3 @@ services: | |
web: | ||
ports: | ||
- "80:80" | ||
environment: | ||
APPLICATION_ENV: dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?php | ||
|
||
return [ | ||
'bootstrap' => ['gii'], | ||
'modules' => [ | ||
'gii' => 'yii\gii\Module', | ||
], | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?php | ||
|
||
$config = [ | ||
'components' => [ | ||
'request' => [ | ||
'cookieValidationKey' => '', | ||
], | ||
], | ||
]; | ||
|
||
if (!YII_ENV_TEST) { | ||
// configuration adjustments for 'dev' environment | ||
$config['bootstrap'][] = 'debug'; | ||
$config['modules']['debug'] = [ | ||
'class' => 'yii\debug\Module', | ||
]; | ||
$config['bootstrap'][] = 'gii'; | ||
$config['modules']['gii'] = [ | ||
'class' => 'yii\gii\Module', | ||
]; | ||
} | ||
|
||
return $config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
|
||
return [ | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php | ||
|
||
defined('YII_DEBUG') or define('YII_DEBUG', true); | ||
defined('YII_ENV') or define('YII_ENV', 'dev'); | ||
|
||
require(__DIR__ . '/../vendor/autoload.php'); | ||
require(__DIR__ . '/../vendor/yiisoft/yii2/Yii.php'); | ||
|
||
$config = yii\helpers\ArrayHelper::merge( | ||
require(__DIR__ . '/../config/common.php'), | ||
require(__DIR__ . '/../config/common-local.php'), | ||
require(__DIR__ . '/../config/main.php'), | ||
require(__DIR__ . '/../config/main-local.php') | ||
); | ||
|
||
(new yii\web\Application($config))->run(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
<?php | ||
/** | ||
* The manifest of files that are local to specific environment. | ||
* This file returns a list of environments that the application | ||
* may be installed under. The returned data must be in the following | ||
* format: | ||
* | ||
* ```php | ||
* return [ | ||
* 'environment name' => [ | ||
* 'path' => 'directory storing the local files', | ||
* 'skipFiles' => [ | ||
* // list of files that should only copied once and skipped if they already exist | ||
* ], | ||
* 'setWritable' => [ | ||
* // list of directories that should be set writable | ||
* ], | ||
* 'setExecutable' => [ | ||
* // list of files that should be set executable | ||
* ], | ||
* 'setCookieValidationKey' => [ | ||
* // list of config files that need to be inserted with automatically generated cookie validation keys | ||
* ], | ||
* 'createSymlink' => [ | ||
* // list of symlinks to be created. Keys are symlinks, and values are the targets. | ||
* ], | ||
* ], | ||
* ]; | ||
* ``` | ||
*/ | ||
return [ | ||
'Development' => [ | ||
'path' => 'dev', | ||
'setWritable' => [ | ||
'runtime', | ||
'web/assets', | ||
], | ||
'setExecutable' => [ | ||
'yii', | ||
], | ||
'setCookieValidationKey' => [ | ||
'config/main-local.php', | ||
], | ||
], | ||
'Production' => [ | ||
'path' => 'prod', | ||
'setWritable' => [ | ||
'runtime', | ||
'web/assets', | ||
], | ||
'setExecutable' => [ | ||
'yii', | ||
], | ||
'setCookieValidationKey' => [ | ||
'config/main-local.php', | ||
], | ||
], | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php | ||
|
||
$config = [ | ||
'components' => [ | ||
'db' => [ | ||
'dsn' => 'mysql:host=;dbname=', | ||
'username' => '', | ||
'password' => '', | ||
], | ||
'mailer' => [ | ||
'class' => 'yii\swiftmailer\Mailer', | ||
], | ||
], | ||
]; | ||
|
||
return $config; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?php | ||
|
||
$config = [ | ||
'components' => [ | ||
'request' => [ | ||
'cookieValidationKey' => '', | ||
], | ||
], | ||
]; | ||
|
||
return $config; |
Oops, something went wrong.