Did you set the environment variables?
May 26, 2019
12
Level 1
Heroku Laravel 403 Forbidden - tried all possible options but cant show page
Cant display my webpage with Laravel 5.8.16 I have tried changing my .htaccess and Procfile but had no luck. My logs are a follows:
2019-05-26T12:14:28.299263+00:00 heroku[router]: at=info method=GET path="/" host=still-forest-63735.herokuapp.com request_id=34d76826-da87-4880-b8b6-c74a6a764b3e fwd="109.150.176.100" dyno=web.1 connect=0ms service=1ms status=403 bytes=373 protocol=https
2019-05-26T12:14:28.299758+00:00 app[web.1]: [Sun May 26 12:14:28.298889 2019] [autoindex:error] [pid 141:tid 140447896823552] [client 10.16.233.224:13780] AH01276: Cannot serve directory /app/: No matching DirectoryIndex (index.php,index.html,index.htm) found, and server-generated directory index forbidden by Options directive
2019-05-26T12:14:28.300168+00:00 app[web.1]: 10.16.233.224 - - [26/May/2019:12:14:28 +0000] "GET / HTTP/1.1" 403 209 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36
PS D:\laravel_testing_project\lar2\laravel> php artisan --version
My .htaccess in public is:
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options +SymLinksIfOwnerMatch.
</IfModule>
RewriteEngine On
# Handle Authorization Header
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule "^(.*)$ public/$1" [L]
</IfModule>
My Procfile is:
"web: vendor/bin/heroku-php-apache2 public/"
Level 20
@ADRIANMCG85 - Did you make changes to index.php? I think the default line should be:
require __DIR__.'/../vendor/autoload.php';
Please or to participate in this conversation.