Commit e4e181f1ba41c0d28a0cb456e7063cb3ca577dc9

Authored by Yarik
1 parent f5a64ec0

Main local

Showing 2 changed files with 42 additions and 17 deletions   Show diff stats
common/config/main-local.php 0 → 100644
  1 +<?php
  2 +return [
  3 + 'components' => [
  4 + 'db' => [
  5 + 'class' => 'yii\db\Connection',
  6 + 'dsn' => 'pgsql:host=localhost;port=5432;dbname=artbox_db',
  7 + 'username' => 'postgres',
  8 + 'password' => '',
  9 + 'schemaMap' => [
  10 + 'pgsql'=> [
  11 + 'class'=>'yii\db\pgsql\Schema',
  12 + 'defaultSchema' => 'public'
  13 + ]
  14 + ],
  15 + ],
  16 + 'mailer' => [
  17 + 'class' => 'yii\swiftmailer\Mailer',
  18 + 'viewPath' => '@common/mail',
  19 + // send all mails to a file by default. You have to set
  20 + // 'useFileTransport' to false and configure a transport
  21 + // for the mailer to send real emails.
  22 + 'useFileTransport' => true,
  23 + ],
  24 + ],
  25 +];
common/config/main.php
@@ -3,7 +3,7 @@ return [ @@ -3,7 +3,7 @@ return [
3 'vendorPath' => dirname(dirname(__DIR__)) . '/vendor', 3 'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
4 'modules' => [ 4 'modules' => [
5 'permit' => [ 5 'permit' => [
6 - 'class' => 'developeruz\db_rbac\Yii2DbRbac', 6 + 'class' => 'app\modules\db_rbac\Yii2DbRbac',
7 'params' => [ 7 'params' => [
8 'userClass' => 'common\models\User' 8 'userClass' => 'common\models\User'
9 ] 9 ]
@@ -52,7 +52,7 @@ return [ @@ -52,7 +52,7 @@ return [
52 //подключаем конфигурации API соц сетей для авторизации 52 //подключаем конфигурации API соц сетей для авторизации
53 53
54 'eauth' => [ 54 'eauth' => [
55 - 'class' => 'common\components\nodge\eauth\src\EAuth', 55 + 'class' => 'nodge\eauth\EAuth',
56 'popup' => true, // Use the popup window instead of redirecting. 56 'popup' => true, // Use the popup window instead of redirecting.
57 'cache' => false, // Cache component name or false to disable cache. Defaults to 'cache' on production environments. 57 'cache' => false, // Cache component name or false to disable cache. Defaults to 'cache' on production environments.
58 'cacheExpire' => 0, // Cache lifetime. Defaults to 0 - means unlimited. 58 'cacheExpire' => 0, // Cache lifetime. Defaults to 0 - means unlimited.
@@ -63,86 +63,86 @@ return [ @@ -63,86 +63,86 @@ return [
63 'services' => [ // You can change the providers and their classes. 63 'services' => [ // You can change the providers and their classes.
64 'google' => [ 64 'google' => [
65 // register your app here: https://code.google.com/apis/console/ 65 // register your app here: https://code.google.com/apis/console/
66 - 'class' => 'common\components\nodge\eauth\src\services\GoogleOAuth2Service', 66 + 'class' => 'nodge\eauth\services\GoogleOAuth2Service',
67 'clientId' => 'artbox-1138', 67 'clientId' => 'artbox-1138',
68 'clientSecret' => '', 68 'clientSecret' => '',
69 'title' => 'Google', 69 'title' => 'Google',
70 ], 70 ],
71 'twitter' => [ 71 'twitter' => [
72 // register your app here: https://dev.twitter.com/apps/new 72 // register your app here: https://dev.twitter.com/apps/new
73 - 'class' => 'common\components\nodge\eauth\src\services\TwitterOAuth1Service', 73 + 'class' => 'nodge\eauth\services\TwitterOAuth1Service',
74 'key' => '8vReLxI63vTs98MBMqhvrszwy', 74 'key' => '8vReLxI63vTs98MBMqhvrszwy',
75 'secret' => 'jOqNbHIkQw4cVKKJkgrMtaEeCcfbeT1GTik4pF6O9D7AmqcwOG', 75 'secret' => 'jOqNbHIkQw4cVKKJkgrMtaEeCcfbeT1GTik4pF6O9D7AmqcwOG',
76 ], 76 ],
77 'yandex' => [ 77 'yandex' => [
78 // register your app here: https://oauth.yandex.ru/client/my 78 // register your app here: https://oauth.yandex.ru/client/my
79 - 'class' => 'common\components\nodge\eauth\src\services\YandexOAuth2Service', 79 + 'class' => 'nodge\eauth\services\YandexOAuth2Service',
80 'clientId' => 'ea13195ac0424ff8a190838bec41bb71', 80 'clientId' => 'ea13195ac0424ff8a190838bec41bb71',
81 'clientSecret' => '911f2c9afcbf4f5f9319b3134c096c86', 81 'clientSecret' => '911f2c9afcbf4f5f9319b3134c096c86',
82 'title' => 'Yandex', 82 'title' => 'Yandex',
83 ], 83 ],
84 'facebook' => [ 84 'facebook' => [
85 // register your app here: https://developers.facebook.com/apps/ 85 // register your app here: https://developers.facebook.com/apps/
86 - 'class' => 'common\components\nodge\eauth\src\services\FacebookOAuth2Service', 86 + 'class' => 'nodge\eauth\services\FacebookOAuth2Service',
87 'clientId' => '1642047622727997', 87 'clientId' => '1642047622727997',
88 'clientSecret' => 'f5b7ba4f062a568678b764fc74cc416e', 88 'clientSecret' => 'f5b7ba4f062a568678b764fc74cc416e',
89 ], 89 ],
90 'yahoo' => [ 90 'yahoo' => [
91 - 'class' => 'common\components\nodge\eauth\src\services\YahooOpenIDService', 91 + 'class' => 'nodge\eauth\services\YahooOpenIDService',
92 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains. 92 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains.
93 ], 93 ],
94 'linkedin' => [ 94 'linkedin' => [
95 // register your app here: https://www.linkedin.com/secure/developer 95 // register your app here: https://www.linkedin.com/secure/developer
96 - 'class' => 'common\components\nodge\eauth\src\services\LinkedinOAuth1Service', 96 + 'class' => 'nodge\eauth\services\LinkedinOAuth1Service',
97 'key' => '77s41eixn3dyvo', 97 'key' => '77s41eixn3dyvo',
98 'secret' => '1xLZQ7RRK6RNjo4U', 98 'secret' => '1xLZQ7RRK6RNjo4U',
99 'title' => 'LinkedIn (OAuth1)', 99 'title' => 'LinkedIn (OAuth1)',
100 ], 100 ],
101 'linkedin_oauth2' => [ 101 'linkedin_oauth2' => [
102 // register your app here: https://www.linkedin.com/secure/developer 102 // register your app here: https://www.linkedin.com/secure/developer
103 - 'class' => 'common\components\nodge\eauth\src\services\LinkedinOAuth2Service', 103 + 'class' => 'nodge\eauth\services\LinkedinOAuth2Service',
104 'clientId' => '77s41eixn3dyvo', 104 'clientId' => '77s41eixn3dyvo',
105 'clientSecret' => '1xLZQ7RRK6RNjo4U', 105 'clientSecret' => '1xLZQ7RRK6RNjo4U',
106 'title' => 'LinkedIn (OAuth2)', 106 'title' => 'LinkedIn (OAuth2)',
107 ], 107 ],
108 'github' => [ 108 'github' => [
109 // register your app here: https://github.com/settings/applications 109 // register your app here: https://github.com/settings/applications
110 - 'class' => 'common\components\nodge\eauth\src\services\GitHubOAuth2Service', 110 + 'class' => 'nodge\eauth\services\GitHubOAuth2Service',
111 'clientId' => 'd00283b5cfb225cd1600', 111 'clientId' => 'd00283b5cfb225cd1600',
112 'clientSecret' => 'f482361fad7184819d452f421c8b09db60830b42', 112 'clientSecret' => 'f482361fad7184819d452f421c8b09db60830b42',
113 ], 113 ],
114 'live' => [ 114 'live' => [
115 // register your app here: https://account.live.com/developers/applications/index 115 // register your app here: https://account.live.com/developers/applications/index
116 - 'class' => 'common\components\nodge\eauth\src\services\LiveOAuth2Service', 116 + 'class' => 'nodge\eauth\services\LiveOAuth2Service',
117 'clientId' => '00000000481796AE', 117 'clientId' => '00000000481796AE',
118 'clientSecret' => 'rt9GiJrlKz3sE6CvdOeuwWyYbl1tQT03', 118 'clientSecret' => 'rt9GiJrlKz3sE6CvdOeuwWyYbl1tQT03',
119 ], 119 ],
120 'steam' => [ 120 'steam' => [
121 - 'class' => 'common\components\nodge\eauth\src\services\SteamOpenIDService', 121 + 'class' => 'nodge\eauth\services\SteamOpenIDService',
122 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains. 122 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains.
123 ], 123 ],
124 'instagram' => [ 124 'instagram' => [
125 // register your app here: https://instagram.com/developer/register/ 125 // register your app here: https://instagram.com/developer/register/
126 - 'class' => 'common\components\nodge\eauth\src\services\InstagramOAuth2Service', 126 + 'class' => 'nodge\eauth\services\InstagramOAuth2Service',
127 'clientId' => '...', 127 'clientId' => '...',
128 'clientSecret' => '...', 128 'clientSecret' => '...',
129 ], 129 ],
130 'vkontakte' => [ 130 'vkontakte' => [
131 // register your app here: https://vk.com/editapp?act=create&site=1 131 // register your app here: https://vk.com/editapp?act=create&site=1
132 - 'class' => 'common\components\nodge\eauth\src\services\VKontakteOAuth2Service', 132 + 'class' => 'nodge\eauth\services\VKontakteOAuth2Service',
133 'clientId' => '5155388', 133 'clientId' => '5155388',
134 'clientSecret' => 'jxgmdGVQw7huGKRpnX3a', 134 'clientSecret' => 'jxgmdGVQw7huGKRpnX3a',
135 ], 135 ],
136 'mailru' => [ 136 'mailru' => [
137 // register your app here: http://api.mail.ru/sites/my/add 137 // register your app here: http://api.mail.ru/sites/my/add
138 - 'class' => 'common\components\nodge\eauth\src\services\MailruOAuth2Service', 138 + 'class' => 'nodge\eauth\services\MailruOAuth2Service',
139 'clientId' => '739322', 139 'clientId' => '739322',
140 'clientSecret' => 'd6ce7be6ff791375adff58fe0e4460b2', 140 'clientSecret' => 'd6ce7be6ff791375adff58fe0e4460b2',
141 ], 141 ],
142 'odnoklassniki' => [ 142 'odnoklassniki' => [
143 // register your app here: http://dev.odnoklassniki.ru/wiki/pages/viewpage.action?pageId=13992188 143 // register your app here: http://dev.odnoklassniki.ru/wiki/pages/viewpage.action?pageId=13992188
144 // ... or here: http://www.odnoklassniki.ru/dk?st.cmd=appsInfoMyDevList&st._aid=Apps_Info_MyDev 144 // ... or here: http://www.odnoklassniki.ru/dk?st.cmd=appsInfoMyDevList&st._aid=Apps_Info_MyDev
145 - 'class' => 'common\components\nodge\eauth\src\services\OdnoklassnikiOAuth2Service', 145 + 'class' => 'nodge\eauth\services\OdnoklassnikiOAuth2Service',
146 'clientId' => '...', 146 'clientId' => '...',
147 'clientSecret' => '...', 147 'clientSecret' => '...',
148 'clientPublic' => '...', 148 'clientPublic' => '...',
@@ -157,7 +157,7 @@ return [ @@ -157,7 +157,7 @@ return [
157 [ 157 [
158 'class' => 'yii\log\FileTarget', 158 'class' => 'yii\log\FileTarget',
159 'logFile' => '@app/runtime/logs/eauth.log', 159 'logFile' => '@app/runtime/logs/eauth.log',
160 - 'categories' => ['common\components\nodge\eauth\nodge\eauth\*'], 160 + 'categories' => ['nodge\eauth\*'],
161 'logVars' => [], 161 'logVars' => [],
162 ], 162 ],
163 ], 163 ],