Modification de l'URL

Post Reply
Minus
Znuny newbie
Posts: 4
Joined: 29 Feb 2016, 15:46
Znuny Version: otrs 5 free
Real Name: Frederic

Modification de l'URL

Post by Minus »

Bonjour à tous

Je suis en train d'installer OTRS pour remplacer GLPI dans ma société.

J'ai besoin d'un petit renseignement.

En suivant le tuto du manuel d'installation de OTRS (téléchargé directement sur le site), j'ai donc une URL d'accés à OTRS comme suit:

http://172.16.12.183/otrs/index.pl

je voudrais juste la changer pour accéder à OTRS via tout simplement: http://172.16.12.183/index.pl

le seul fichier de config dans apache2 est le renvoi suivant dans /etc/apache2/conf-enabled

zzz_otrs.conf -> /opt/otrs/scripts/apache2-httpd.include.conf

et donc le fichier apache2-httpd.include.conf est le suivant:

Code: Select all

# --
# added for OTRS (http://otrs.org/)
# --

ScriptAlias /otrs/ "/opt/otrs/bin/cgi-bin/"
Alias /otrs-web/ "/opt/otrs/var/httpd/htdocs/"

<IfModule mod_perl.c>

    # Setup environment and preload modules
    Perlrequire /opt/otrs/scripts/apache2-perl-startup.pl

    # Reload Perl modules when changed on disk
    PerlModule Apache2::Reload
    PerlInitHandler Apache2::Reload

    # general mod_perl2 options
    <Location /otrs>
#        ErrorDocument 403 /otrs/customer.pl
        ErrorDocument 403 /otrs/index.pl
        SetHandler  perl-script
        PerlResponseHandler ModPerl::Registry
        Options +ExecCGI
        PerlOptions +ParseHeaders
        PerlOptions +SetupEnv

        <IfModule mod_version.c>
            <IfVersion < 2.4>
                Order allow,deny
                Allow from all
            </IfVersion>
            <IfVersion >= 2.4>
                Require all granted
            </IfVersion>
        </IfModule>
        <IfModule !mod_version.c>
            Order allow,deny
            Allow from all
        </IfModule>
    </Location>

    # mod_perl2 options for GenericInterface
    <Location /otrs/nph-genericinterface.pl>
        PerlOptions -ParseHeaders
    </Location>

</IfModule>

<Directory "/opt/otrs/bin/cgi-bin/">
    AllowOverride None
    Options +ExecCGI -Includes

    <IfModule mod_version.c>
        <IfVersion < 2.4>
            Order allow,deny
            Allow from all
        </IfVersion>
        <IfVersion >= 2.4>
            Require all granted
        </IfVersion>
    </IfModule>
    <IfModule !mod_version.c>
        Order allow,deny
        Allow from all
    </IfModule>

    <IfModule mod_filter.c>
        <IfModule mod_deflate.c>
            AddOutputFilterByType DEFLATE text/html text/javascript application/javascript text/css text/xml application/json text/json
         </IfModule>
    </IfModule>

</Directory>

<Directory "/opt/otrs/var/httpd/htdocs/">
    AllowOverride None

    <IfModule mod_version.c>
        <IfVersion < 2.4>
            Order allow,deny
            Allow from all
        </IfVersion>
        <IfVersion >= 2.4>
            Require all granted
        </IfVersion>
    </IfModule>
    <IfModule !mod_version.c>
        Order allow,deny
        Allow from all
    </IfModule>

    <IfModule mod_filter.c>
        <IfModule mod_deflate.c>
            AddOutputFilterByType DEFLATE text/html text/javascript application/javascript text/css text/xml application/json text/json
         </IfModule>
    </IfModule>

    # Make sure CSS and JS files are read as UTF8 by the browsers.
    AddCharset UTF-8 .css
    AddCharset UTF-8 .js

    # Set explicit mime type for woff fonts since it is relatively new and apache may not know about it.
    AddType application/font-woff .woff

</Directory>

<IfModule mod_headers.c>
    # Cache css-cache for 30 days
    <Directory "/opt/otrs/var/httpd/htdocs/skins/*/*/css-cache">
        <FilesMatch "\.(css|CSS)$">
            Header set Cache-Control "max-age=2592000 must-revalidate"
        </FilesMatch>
    </Directory>

    # Cache css thirdparty for 4 hours, including icon fonts
    <Directory "/opt/otrs/var/httpd/htdocs/skins/*/*/css/thirdparty">
        <FilesMatch "\.(css|CSS|woff|svg)$"> 
                    Header set Cache-Control "max-age=14400 must-revalidate"
        </FilesMatch>
    </Directory>

    # Cache js-cache for 30 days
    <Directory "/opt/otrs/var/httpd/htdocs/js/js-cache">
        <FilesMatch "\.(js|JS)$">
            Header set Cache-Control "max-age=2592000 must-revalidate"
        </FilesMatch>
    </Directory>

    # Cache js thirdparty for 4 hours
    <Directory "/opt/otrs/var/httpd/htdocs/js/thirdparty/">
        <FilesMatch "\.(js|JS)$">
            Header set Cache-Control "max-age=14400 must-revalidate"
        </FilesMatch>
    </Directory>
</IfModule>

# Limit the number of requests per child to avoid excessive memory usage
MaxRequestsPerChild 4000              
que dois je modifier dans ce fichier pour avoir l'url d'accés comme je le désire?

Par avance merci
wheelshot
Znuny expert
Posts: 188
Joined: 15 Dec 2014, 20:49
Znuny Version: 4.0.24
Location: QC, Canada

Re: Modification de l'URL

Post by wheelshot »

As-tu modifié sans le Sysconfig les paramètres FQDN et ScriptAlias dans la partie Framework? Je sais que pour moi, cela causait un bug.
Minus
Znuny newbie
Posts: 4
Joined: 29 Feb 2016, 15:46
Znuny Version: otrs 5 free
Real Name: Frederic

Re: Modification de l'URL

Post by Minus »

Bonjour

Pour le moment je n'ai rien modifié de ce coté la
wheelshot
Znuny expert
Posts: 188
Joined: 15 Dec 2014, 20:49
Znuny Version: 4.0.24
Location: QC, Canada

Re: Modification de l'URL

Post by wheelshot »

Minus wrote:Bonjour

Pour le moment je n'ai rien modifié de ce coté la
Fais nous signe si cela corrige ton problème
Post Reply