Le 20 août 2014 15:03, "Simon Paillard" <spaill...@debian.org> a écrit :
> Indeed in apache conf:
>    # we never want to rewrite those URLs
>    [..]
>    RewriteRule ^/[^/]+\.css - [L]
>    RewriteRule ^/[^/]+\.js - [L]
>    RewriteRule ^/favicon.ico$ - [L]
>    RewriteRule ^/robots.txt$ - [L]
>    [..]
>    RewriteRule ^/([^/]+)$               /search?keywords=$1 [R,L,NE]
>
> As :
> * we want to keep the url http://pdo/$package working
> * policy allows package name to end with .css .js or even be named
favicon.ico
>
> --> What about moving static *css and *js to a static dir ?

It's probably a good solution but using http://pdo/static/*.(css,js) will
be confusing if there is a package named 'static'. However, we could use a
more specific name to mitigate the problem ('static-files' or even
'static-files-for-pdo' for example). We could wait until the problem occurs
too but if the changes are done, it's a no-cost to use a name more specific.

Using a sub-domain (like http://static-package.d.o) is probably a bad idea
because it will need an additional configuration for the *js files due to
security policy of the web browsers.

The favico.ico could be replaced by a standard image (png, jpg) if it's not
currently the case. The tag is 'link rel="icon"'. It could not work on old
browsers. If the site uses the tag, the apache configuration for favicon
could be removed and any package could be called 'favicon.ico'.

Reply via email to