Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

630
Vistas
How to fix Laravel Error 404 in acceptance environment?

I try to install my Laravel application in a new environment acceptance,

After composer install (no errors)

when I check the url it's redirected to /login which is normal

The problem: it returns 404 error and this error is coming from the server not from Laravel because I customized 404 error in my application

enter image description here

it seems like the server does accept only / path :

also when I change the router :

from

Route::get('/', function () {
    if (Auth::check()) return redirect('/myprofile');
    return redirect('/login');
});

To this:

Route::get('/', function () {
    return 'hello world'
});

it works and I can see hello world

the route /login exists when I route:list

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

First check if Apache's mod_rewrite module is enabled, If it's not enabled aleady please run below commands to enable it or else jump to second part of the answer

sudo a2enmod rewrite
sudo service apache2 restart

Also add below config block in your virtual host configuration to enable laravels .htaccess rules

<Directory /var/www/>
    Options Indexes FollowSymLinks
    AllowOverride All
    Require all granted
</Directory>

Change /var/www/ path accordingly

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda