close
Warning:
Can't synchronize with repository "(default)" (Unsupported version control system "darcs": Can't find an appropriate component, maybe the corresponding plugin was not enabled? ). Look in the Trac log for more information.
- Timestamp:
-
2011-11-18 01:44:17 (13 years ago)
- Author:
-
trac
- Comment:
-
--
Legend:
- Unmodified
- Added
- Removed
- Modified
-
v1
|
v2
|
|
64 | 64 | Web servers such as [http://httpd.apache.org/ Apache] allow you to create “Aliases” to resources, giving them a virtual URL that doesn't necessarily reflect the layout of the servers file system. We already used this capability by defining a `ScriptAlias` for the CGI script. We also can map requests for static resources directly to the directory on the file system, avoiding processing these requests by CGI script. |
65 | 65 | |
| 66 | There are two primary URL paths for static resources - `/chrome/common` and `/chrome/site`. Plugins can add their own resources usually accessible by `/chrome/plugin` path, so its important to override only known paths and not try to make universal `/chrome` alias for everything. |
| 67 | |
66 | 68 | Add the following snippet to Apache configuration '''before''' the `ScriptAlias` for the CGI script, changing paths to match your deployment: |
67 | 69 | {{{ |
68 | | Alias /trac/chrome/common /path/to/www/trac/htdocs |
| 70 | Alias /trac/chrome/common /path/to/trac/htdocs/common |
| 71 | Alias /trac/chrome/site /path/to/trac/htdocs/site |
69 | 72 | <Directory "/path/to/www/trac/htdocs"> |
70 | 73 | Order allow,deny |
71 | 74 | Allow from all |
72 | 75 | </Directory> |
| 76 | }}} |
| 77 | |
| 78 | If using mod_python, you might want to add this too (otherwise, the alias will be ignored): |
| 79 | {{{ |
| 80 | <Location "/trac/chrome/common/"> |
| 81 | SetHandler None |
| 82 | </Location> |
73 | 83 | }}} |
74 | 84 | |