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

151
Vistas
Multiple websites infinite index.php loop

I'm trying to dispatch different Symfony website within the same domain. I actually have 1 folder for each of them like :

html/site1
html/site2
html/...

Here is the .conf (CentOS & Apache) :

AliasMatch "^/site1(.*)" "/var/www/html/site1/public"
<VirtualHost *:80>
    ServerName example.com
    ServerAlias https://example.com

    DocumentRoot /var/www/html/site1/public
    <Directory /var/www/html/site1/public>
        AllowOverride All
        Order Allow,Deny
        Allow from All

        <IfModule mod_rewrite.c>
            Options -MultiViews
            RewriteEngine On
            RewriteCond %{REQUEST_FILENAME} !-f
            RewriteRule ^(.*)$ index.php [QSA,L]
        </IfModule>
    </Directory>
    ErrorLog /etc/httpd/conf.d/site1.log
</VirtualHost>

AliasMatch "^/site2(.*)" "/var/www/html/site2/public"
<VirtualHost *:80>
    ServerName example.com
    ServerAlias https://example.com

    DocumentRoot /var/www/html/site2/public
    <Directory /var/www/html/site2/public>
        AllowOverride All
        Order Allow,Deny
        Allow from All

        <IfModule mod_rewrite.c>
            Options -MultiViews
            RewriteEngine On
            RewriteCond %{REQUEST_FILENAME} !-f
            RewriteRule ^(.*)$ index.php [QSA,L]
        </IfModule>
    </Directory>
    ErrorLog /etc/httpd/conf.d/site2.log
</VirtualHost>

The AliasMatch seems to work, but I get an infinite loop as the result is :

example.com/siteX/index.php/index.php/index.php/index.php/index.php/index.php/... ERR_TOO_MANY_REDIRECTS

It looks like the server is trying to redirect me even if I get a response from the site, because logs are writing as if everything was working.

over 4 years ago · Santiago Trujillo
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