aboutsummaryrefslogtreecommitdiffstats
path: root/config/squid/squid.inc
diff options
context:
space:
mode:
Diffstat (limited to 'config/squid/squid.inc')
-rw-r--r--config/squid/squid.inc9
1 files changed, 6 insertions, 3 deletions
diff --git a/config/squid/squid.inc b/config/squid/squid.inc
index f804ef87..e4bb1e58 100644
--- a/config/squid/squid.inc
+++ b/config/squid/squid.inc
@@ -1125,6 +1125,8 @@ function squid_resync() {
mwexec("/usr/local/sbin/squid -k reconfigure");
}
+ // Sleep for a couple seconds to give squid a chance to fire up fully.
+ sleep(5);
filter_configure();
conf_mount_ro();
}
@@ -1256,12 +1258,13 @@ function squid_generate_rules($type) {
global $config;
$squid_conf = $config['installedpackages']['squid']['config'][0];
- if (!is_service_running('squid')) {
- log_error("SQUID is installed but not started. Not installing redirect rules.");
+
+ if (($squid_conf['transparent_proxy'] != 'on') || ($squid_conf['allow_interface'] != 'on')) {
return;
}
- if (($squid_conf['transparent_proxy'] != 'on') || ($squid_conf['allow_interface'] != 'on')) {
+ if (!is_service_running('squid')) {
+ log_error("SQUID is installed but not started. Not installing \"{$type}\" rules.");
return;
}