Compare commits

...

4 Commits

Author SHA1 Message Date
mironov 6b1700cf56 Merge pull request 'init' (#4) from init into main
Reviewed-on: #4
2024-07-05 10:29:57 +03:00
Igor Mironov dad2d1df30 init 2024-07-05 10:29:14 +03:00
Igor Mironov 8bc03dcaff init 2024-07-05 10:29:10 +03:00
Igor Mironov c53235a18c init 2024-07-05 10:27:50 +03:00
8 changed files with 6343 additions and 22 deletions

7
.gitignore vendored
View File

@ -41,3 +41,10 @@ phpunit.phar
/backend/web/index.php /backend/web/index.php
/backend/web/index-test.php /backend/web/index-test.php
/backend/web/robots.txt /backend/web/robots.txt
#composer
composer.lock
#docker
/docker/logs/nginx
/docker/logs/mysql

View File

@ -74,9 +74,9 @@ backend: [admin.web.local](http://admin.web.local)
Url stage: Url stage:
frontend: [example.webeffector.ru](https://example.webeffector.ru) frontend: [dev-php.webeffector.net/](https://dev-php.webeffector.net/)
backend: [admin-example.webeffector.ru](https://admin-example.webeffector.ru) backend: [admin-dev-php.webeffector.net/](https://admin-dev-php.webeffector.net/)
Test data for stage/dev: Test data for stage/dev:

View File

@ -1,4 +1,11 @@
<?php <?php
use yii\i18n\Formatter;
use yii\rbac\DbManager;
use yii\caching\FileCache;
use yii\caching\DummyCache;
use yii\i18n\PhpMessageSource;
return [ return [
'aliases' => [ 'aliases' => [
'@bower' => '@vendor/bower-asset', '@bower' => '@vendor/bower-asset',
@ -6,8 +13,46 @@ return [
], ],
'vendorPath' => dirname(dirname(__DIR__)) . '/vendor', 'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
'components' => [ 'components' => [
'formatter' => [
'class' => Formatter::class,
'defaultTimeZone' => 'Europe/Moscow',
'currencyCode' => 'rub',
],
'cache' => [ 'cache' => [
'class' => \yii\caching\FileCache::class, 'class' => YII_ENV_DEV ? DummyCache::class : FileCache::class,
],
'authManager' => [
'class' => DbManager::class,
],
'assetManager' => [
// timeStamp css files
'appendTimestamp' => YII_ENV_DEV, //true|false
],
'i18n' => [
'translations' => [
'app*' => [
'class' => PhpMessageSource::class,
'basePath' => '@common/messages',
'fileMap' => [
'app' => 'app.php',
'error' => 'error.php',
],
],
'user*' => [
'class' => PhpMessageSource::class,
'basePath' => '@backend/modules/user/messages',
'fileMap' => [
'user' => 'user.php',
],
],
'schema*' => [
'class' => PhpMessageSource::class,
'basePath' => '@frontend/modules/schema/messages',
'fileMap' => [
'schema' => 'schema.php',
],
],
],
], ],
], ],
]; ];

6262
composer.lock generated Normal file

File diff suppressed because it is too large Load Diff

View File

@ -21,6 +21,13 @@ return [
'class' => \yii\console\controllers\FixtureController::class, 'class' => \yii\console\controllers\FixtureController::class,
'namespace' => 'common\fixtures', 'namespace' => 'common\fixtures',
], ],
'migrate' => [
'class' => yii\console\controllers\MigrateController::class,
'migrationNamespaces' => [
'backend\modules\user\migrations',
'backend\modules\schema\migrations',
],
],
], ],
'components' => [ 'components' => [
'log' => [ 'log' => [

View File

@ -1,18 +0,0 @@
192.168.65.1 - - [13/Jun/2024:16:34:40 +0300] "GET / HTTP/1.1" 403 187 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:34:40 +0300] "GET /favicon.ico HTTP/1.1" 200 318 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET / HTTP/1.1" 200 1545 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET /css/site.css HTTP/1.1" 200 1858 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET /assets/46f1484b/dist/css/bootstrap.css HTTP/1.1" 200 281046 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET /assets/f5fa1b4e/jquery.js HTTP/1.1" 200 285314 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET /assets/e5b7c8da/yii.js HTTP/1.1" 200 20981 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:16:49:29 +0300] "GET /assets/46f1484b/dist/js/bootstrap.bundle.js HTTP/1.1" 200 207819 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:12:31 +0300] "GET / HTTP/1.1" 200 1545 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:12:31 +0300] "GET /assets/f5fa1b4e/jquery.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:12:31 +0300] "GET /assets/46f1484b/dist/css/bootstrap.css HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:12:31 +0300] "GET /assets/e5b7c8da/yii.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:12:31 +0300] "GET /assets/46f1484b/dist/js/bootstrap.bundle.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:15:11 +0300] "GET / HTTP/1.1" 200 1545 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:15:11 +0300] "GET /assets/46f1484b/dist/css/bootstrap.css HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:15:11 +0300] "GET /assets/f5fa1b4e/jquery.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:15:11 +0300] "GET /assets/e5b7c8da/yii.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"
192.168.65.1 - - [13/Jun/2024:17:15:11 +0300] "GET /assets/46f1484b/dist/js/bootstrap.bundle.js HTTP/1.1" 304 0 "http://web.local/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36"

View File

@ -1 +0,0 @@
2024/06/13 16:34:40 [error] 29#29: *1 directory index of "/var/www/frontend/web/" is forbidden, client: 192.168.65.1, server: content.local, request: "GET / HTTP/1.1", host: "web.local"

View File

@ -48,6 +48,25 @@ return [
'frontend/config/main-local.php', 'frontend/config/main-local.php',
], ],
], ],
'Staging' => [
'path' => 'stage',
'setWritable' => [
'backend/runtime',
'backend/web/assets',
'console/runtime',
'frontend/runtime',
'frontend/web/assets',
],
'setExecutable' => [
'yii',
'yii_test',
],
'setCookieValidationKey' => [
'backend/config/main-local.php',
'common/config/codeception-local.php',
'frontend/config/main-local.php',
],
],
'Production' => [ 'Production' => [
'path' => 'prod', 'path' => 'prod',
'setWritable' => [ 'setWritable' => [