Search squid archive

Re: How to redirect all squid's error pages to one?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 20/05/17 00:44, Dijxie wrote:

Hi list,

1. I'd like to redirect **all** squid error pages to one, universal, preferably internal squid error page. For sure I can symlink every error page to one, but is there a clener way?
I'm not sure if I get it: http://www.squid-cache.org/Doc/config/deny_info/


deny_info is to provide some non-default response payload (aka. "page") instead of the 403 when an ACL performs administrative denial of access.

As to your purpose; What is this universal message that conveys all possible environmental conditions to the reader in one simple text?

Keep in mind that the reader may not be human; some errors are explanations of indirect problems and only visible when the accompanying machine instructions reach a failure (eg 30x, 401, 407 messages); and some are not errors at all but instructions for a user on what they need to do to continue with communication (eg 511 login pages).

2. And then, using %e code and presumably external js nested in this page, display more detailed info for some error numbers.

Can it be done? Can squid internal web server handle easy js?


Squid is not a web server. On "error" it produces message payloads which happen to contain HTML by default. Modern HTML can contain embedded scripts, but they are not interpreted by Squid as anything beyond opaque characters.


If you redirect all errors to one URL any information the client might have had about the error is destroyed.

The symlinking you though of is the "best" way to do what you are asking for. However, think carefully about what the purpose of displaying an error message is, see above.

Amos

_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users




[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux