Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.x] fixing the new maintenance mode #34277

Closed
wants to merge 1 commit into from
Closed

[8.x] fixing the new maintenance mode #34277

wants to merge 1 commit into from

Conversation

Hesammousavi
Copy link
Contributor

@Hesammousavi Hesammousavi commented Sep 11, 2020

OS : window 10
Laravel Version: 8.x
PHP Version: 7.3.9
Database Driver & Version: none

Description:

according to this issue #34085
i cant use maintenance mode --render when it's down.
after change this line

if (! file_exists($down = __DIR__.'/../storage/framework/down')) { // <-------------- this one
    return;
}

to this one

if (! file_exists($down = $_SERVER['DOCUMENT_ROOT'] .'/../storage/framework/down')) { // <-------------- this one
    return;
}

the problem fix for me.

@taylorotwell
Copy link
Member

I would like a better explanation from people as to why the current code does not work. It should clearly work and works on my machine and for others as well. It's pretty straight forward code.

@Hesammousavi
Copy link
Contributor Author

but it doesn't work for me as well in my machine
i don't know why the exact problem here
but if i change the line the problem will fix :\

@Hesammousavi
Copy link
Contributor Author

i setup php , mysql with xampp on my machine
in my macbook or windows i get this same problem

@willrowe
Copy link
Contributor

@taylorotwell I tried my best to explain in my comment here why this is hard to test and how it seems to be working even though it is not. Perhaps the simplest way to see whether this is working correctly or not would be to add:

var_dump('bypassing framework');
die

after this block and:

var_dump('using framework');
die

after this block. Then you can run the down command using different options and see whether it is bypassing the framework when you expect it to.

@driesvints
Copy link
Member

Please reply to #34085 (comment) so we can focus the discussion in one place.

@laravel laravel locked and limited conversation to collaborators Sep 11, 2020
@taylorotwell taylorotwell reopened this Sep 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants