Updated Docker files and double check the login provider.

This commit is contained in:
James Cole 2018-10-19 09:51:58 +02:00
parent 8f00d2b616
commit dd0cc2d173
6 changed files with 10 additions and 8 deletions

View File

@ -59,7 +59,7 @@ class ForgotPasswordController extends Controller
*/
public function sendResetLinkEmail(Request $request, UserRepositoryInterface $repository)
{
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
if ('eloquent' !== $loginProvider) {
$message = sprintf('Cannot reset password when authenticating over "%s".', $loginProvider);
Log::error($message);
@ -98,7 +98,7 @@ class ForgotPasswordController extends Controller
*/
public function showLinkRequestForm()
{
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
if ('eloquent' !== $loginProvider) {
$message = sprintf('Cannot reset password when authenticating over "%s".', $loginProvider);

View File

@ -130,7 +130,7 @@ class LoginController extends Controller
public function showLoginForm(Request $request)
{
$count = DB::table('users')->count();
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
if (0 === $count && 'eloquent' === $loginProvider) {
return redirect(route('register')); // @codeCoverageIgnore
}

View File

@ -72,7 +72,7 @@ class RegisterController extends Controller
{
// is allowed to?
$allowRegistration = true;
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
$singleUserMode = FireflyConfig::get('single_user_mode', config('firefly.configuration.single_user_mode'))->data;
$userCount = User::count();
if (true === $singleUserMode && $userCount > 0 && 'eloquent' === $loginProvider) {
@ -113,7 +113,7 @@ class RegisterController extends Controller
public function showRegistrationForm(Request $request)
{
$allowRegistration = true;
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
$isDemoSite = FireflyConfig::get('is_demo_site', config('firefly.configuration.is_demo_site'))->data;
$singleUserMode = FireflyConfig::get('single_user_mode', config('firefly.configuration.single_user_mode'))->data;
$userCount = User::count();

View File

@ -71,7 +71,7 @@ class ResetPasswordController extends Controller
*/
public function showResetForm(Request $request, $token = null)
{
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
if ('eloquent' !== $loginProvider) {
$message = sprintf('Cannot reset password when authenticating over "%s".', $loginProvider);
@ -103,7 +103,7 @@ class ResetPasswordController extends Controller
*/
public function reset(Request $request)
{
$loginProvider = env('LOGIN_PROVIDER','eloquent');
$loginProvider = envNonEmpty('LOGIN_PROVIDER','eloquent');
if ('eloquent' !== $loginProvider) {
$message = sprintf('Cannot reset password when authenticating over "%s".', $loginProvider);

View File

@ -71,6 +71,7 @@ use FireflyIII\Validation\FireflyValidator;
use Illuminate\Foundation\Application;
use Illuminate\Support\ServiceProvider;
use Twig;
use Twig_Extension_Debug;
use TwigBridge\Extension\Loader\Functions;
use Validator;
@ -105,6 +106,7 @@ class FireflyServiceProvider extends ServiceProvider
Twig::addExtension(new Transaction);
Twig::addExtension(new Rule);
Twig::addExtension(new AmountFormat);
Twig::addExtension(new Twig_Extension_Debug);
}
/**

View File

@ -14,7 +14,7 @@ services:
- FF_DB_CONNECTION=pgsql
- TZ=Europe/Amsterdam
- APP_LOG_LEVEL=debug
image: jc5x/firefly-iii:develop
image: jc5x/firefly-iii
links:
- firefly_iii_db
networks: