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 3 'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
4 4 'modules' => [
5 5 'permit' => [
6   - 'class' => 'developeruz\db_rbac\Yii2DbRbac',
  6 + 'class' => 'app\modules\db_rbac\Yii2DbRbac',
7 7 'params' => [
8 8 'userClass' => 'common\models\User'
9 9 ]
... ... @@ -52,7 +52,7 @@ return [
52 52 //подключаем конфигурации API соц сетей для авторизации
53 53  
54 54 'eauth' => [
55   - 'class' => 'common\components\nodge\eauth\src\EAuth',
  55 + 'class' => 'nodge\eauth\EAuth',
56 56 'popup' => true, // Use the popup window instead of redirecting.
57 57 'cache' => false, // Cache component name or false to disable cache. Defaults to 'cache' on production environments.
58 58 'cacheExpire' => 0, // Cache lifetime. Defaults to 0 - means unlimited.
... ... @@ -63,86 +63,86 @@ return [
63 63 'services' => [ // You can change the providers and their classes.
64 64 'google' => [
65 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 67 'clientId' => 'artbox-1138',
68 68 'clientSecret' => '',
69 69 'title' => 'Google',
70 70 ],
71 71 'twitter' => [
72 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 74 'key' => '8vReLxI63vTs98MBMqhvrszwy',
75 75 'secret' => 'jOqNbHIkQw4cVKKJkgrMtaEeCcfbeT1GTik4pF6O9D7AmqcwOG',
76 76 ],
77 77 'yandex' => [
78 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 80 'clientId' => 'ea13195ac0424ff8a190838bec41bb71',
81 81 'clientSecret' => '911f2c9afcbf4f5f9319b3134c096c86',
82 82 'title' => 'Yandex',
83 83 ],
84 84 'facebook' => [
85 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 87 'clientId' => '1642047622727997',
88 88 'clientSecret' => 'f5b7ba4f062a568678b764fc74cc416e',
89 89 ],
90 90 'yahoo' => [
91   - 'class' => 'common\components\nodge\eauth\src\services\YahooOpenIDService',
  91 + 'class' => 'nodge\eauth\services\YahooOpenIDService',
92 92 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains.
93 93 ],
94 94 'linkedin' => [
95 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 97 'key' => '77s41eixn3dyvo',
98 98 'secret' => '1xLZQ7RRK6RNjo4U',
99 99 'title' => 'LinkedIn (OAuth1)',
100 100 ],
101 101 'linkedin_oauth2' => [
102 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 104 'clientId' => '77s41eixn3dyvo',
105 105 'clientSecret' => '1xLZQ7RRK6RNjo4U',
106 106 'title' => 'LinkedIn (OAuth2)',
107 107 ],
108 108 'github' => [
109 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 111 'clientId' => 'd00283b5cfb225cd1600',
112 112 'clientSecret' => 'f482361fad7184819d452f421c8b09db60830b42',
113 113 ],
114 114 'live' => [
115 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 117 'clientId' => '00000000481796AE',
118 118 'clientSecret' => 'rt9GiJrlKz3sE6CvdOeuwWyYbl1tQT03',
119 119 ],
120 120 'steam' => [
121   - 'class' => 'common\components\nodge\eauth\src\services\SteamOpenIDService',
  121 + 'class' => 'nodge\eauth\services\SteamOpenIDService',
122 122 //'realm' => '*.example.org', // your domain, can be with wildcard to authenticate on subdomains.
123 123 ],
124 124 'instagram' => [
125 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 127 'clientId' => '...',
128 128 'clientSecret' => '...',
129 129 ],
130 130 'vkontakte' => [
131 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 133 'clientId' => '5155388',
134 134 'clientSecret' => 'jxgmdGVQw7huGKRpnX3a',
135 135 ],
136 136 'mailru' => [
137 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 139 'clientId' => '739322',
140 140 'clientSecret' => 'd6ce7be6ff791375adff58fe0e4460b2',
141 141 ],
142 142 'odnoklassniki' => [
143 143 // register your app here: http://dev.odnoklassniki.ru/wiki/pages/viewpage.action?pageId=13992188
144 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 146 'clientId' => '...',
147 147 'clientSecret' => '...',
148 148 'clientPublic' => '...',
... ... @@ -157,7 +157,7 @@ return [
157 157 [
158 158 'class' => 'yii\log\FileTarget',
159 159 'logFile' => '@app/runtime/logs/eauth.log',
160   - 'categories' => ['common\components\nodge\eauth\nodge\eauth\*'],
  160 + 'categories' => ['nodge\eauth\*'],
161 161 'logVars' => [],
162 162 ],
163 163 ],
... ...