On 12/11/2013 06:23 AM, Ala Maison wrote:
What file is that because i looked in all apache configuration files
and i couldn't find the Scriptalias or WSGIScriptAlias they are
talking about :/

It would be in the apache config for that site. Here's mine for reference (with appropriate parts redacted, naturally):

# Redirect plain requests to the https://
<VirtualHost *:80>
    ServerName trac.fqdn
    ServerAlias trac
    RewriteEngine on
    RewriteRule . https://trac.fqdn/%{REQUEST_URI}
</VirtualHost>

# Rewritelocks can't be in a VirtualHost section
RewriteLock /var/run/apache2.rewritelock

# trac serves trac
<VirtualHost *:443>
    ServerName trac.fqdn
    ServerAlias trac

    # Serve (relatively) static chrome files directly from the
    # filesystem. Use trac-admin's deploy command to create the
    # static-htdocs directory:
    Alias /trac/chrome /opt/trac/eng/static-htdocs/htdocs
    <Directory "/opt/trac/eng/static-htdocs/htdocs">
        Order allow,deny
        Allow from all
    </Directory>

    WSGIDaemonProcess trac user=www-data group=www-data threads=50
    WSGIScriptAlias /trac /opt/trac/eng/static-htdocs/cgi-bin/trac.wsgi
    RewriteEngine on

    # RewriteLog /var/log/apache2/rewrite.log
    # RewriteLogLevel 9

    # SSL stuff
    SSLEngine on
    SSLCertificateFile /etc/apache2/ssl/server_cert.pem
    SSLCertificateKeyFile /etc/apache2/ssl/private.key
    SSLCertificateChainFile /etc/apache2/ssl/cert_chain.pem

    # It would be far better if mod_fcgid respected the setting of LANG
    # in the actual environment, but I don't know how to do that easily.
    # It seems mod_fcgid includes _only_ the environment values
    # specifically set below, so we do need to set LANG here explicitly.
    # See ticket #1352
    DefaultInitEnv LANG "en_US.UTF-8"
    DefaultInitEnv TRAC_ENV "/opt/trac/eng"

    # Redirect bare requests to /trac
    RewriteCond %{REQUEST_URI} ^/$
    RewriteRule ^(.*)$ https://trac.fqdn/trac%{REQUEST_URI}

    # force fully qualified domain name
    RewriteCond %{HTTP_HOST}    !^trac\.fqdn
    RewriteCond %{HTTP_HOST}    !^$
    RewriteRule ^/(.*)          https://trac.fqdn/$1

    <Directory /opt/trac/eng/static-htdocs/cgi-bin/>
        WSGIProcessGroup trac
        WSGIApplicationGroup %{GLOBAL}
        Order deny,allow
        Allow from all
    </Directory>

    # It's very likely that this section does nothing since mod_fcgid
    # appears to only pass variables set via DefaultInitEnv, but why fix
    # something that isn't broken?
    <Location "/trac">
          SetEnv TRAC_ENV "/opt/trac/eng"
    </Location>

    # This is likely redundant with the http redirect, above, but
    # let's be explicit about not sending credentials in plain text,
    # shall we?
    <Location "/trac/login">
          SSLRequireSSL
    </Location>
</VirtualHost>


--
Matthew Caron, Software Build Engineer
Red Lion Controls | www.redlion.net
+1 (518) 877-5173 x138 office

--
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/trac-users.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to