You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2025-03-05 07:12:05

wjqwh
Member
Registered: 2025-02-19
Posts: 19

glpi virtual host configuration

Hello,

I have a problem with glpi virtaul host configuration.
https[:]//abc.local   --can access glpi
https[:]//abc.local/portal    --http error 403, you have no user right to access
what's the problem, How can I do?  My aim is both of them can be https access:
Thanks so much!


Here is my folder structure:
www
   html
       glpi-cn
       portal

Here is virtual host configuration found in this forum:

<VirtualHost *:443>
    ServerName abc.local
    DocumentRoot /var/www/html/glpi-cn/public
        SSLEngine on
        SSLCertificateFile      /root/certificate/certificate.cer
        SSLCertificateKeyFile   /root/certificate/name.pem
        SSLCertificateChainFile /root/certificate/CABundle.crt
    <Directory /var/www/html/glpi-cn/public>
        Require all granted
        RewriteEngine On
        # Redirect all requests to GLPI router, unless file exists.
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteRule ^(.*)$ index.php [QSA,L]
    </Directory>
<Directory /var/www/html/portal>
   Require all granted
</Directory>

</VirtualHost>

Last edited by wjqwh (2025-03-05 07:30:38)

Offline

#2 2025-03-05 10:12:34

tofou
Member
From: Saint-Lô
Registered: 2007-02-26
Posts: 99

Re: glpi virtual host configuration

Hello,
I think you should add an alias for your portal
Somethink like : Alias /portal /var/www/html/portal (under ServerName)
Regards


GLPI : 10.0.16
OS : RH9 + Apache
php : 8.3.11,
MariaDB : 10.11.9

Offline

#3 2025-03-05 12:47:25

wjqwh
Member
Registered: 2025-02-19
Posts: 19

Re: glpi virtual host configuration

when add this alias, https[:]//abc.local/portal  is ok,  but  https[:]//abc.local will display Apache default page.

Offline

#4 2025-03-05 12:52:01

wjqwh
Member
Registered: 2025-02-19
Posts: 19

Re: glpi virtual host configuration

if add two alias list below, both of them are ok.  but  the glpi will display warning:
Web server root directory configuration is not safe as it permits access to non-public files. See installation documentation for more details.

Alias "/" "/var/www/html/glpi-cn/"
Alias "/portal" "/var/www/html/portal"

So, how to solve this problem.
Thanks.

Last edited by wjqwh (2025-03-05 12:52:32)

Offline

Board footer

Powered by FluxBB