aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/varnish64/varnish.inc7
1 files changed, 6 insertions, 1 deletions
diff --git a/config/varnish64/varnish.inc b/config/varnish64/varnish.inc
index 4f54d288..e098e20a 100644
--- a/config/varnish64/varnish.inc
+++ b/config/varnish64/varnish.inc
@@ -31,6 +31,7 @@
*/
/* ========================================================================== */
+/* Return true if a backend is in use */
function is_varnish_backend_in_use($backendname) {
global $g, $config;
if($config['installedpackages']['varnishlbdirectors']['config'] != "")
@@ -48,6 +49,7 @@ function is_varnish_backend_in_use($backendname) {
return false;
}
+/* Build the URL mappings logic VCL config txt */
function varnish_get_url_mappings_txt() {
global $g, $config, $urlmappings;
$backends = "";
@@ -272,11 +274,12 @@ sub vcl_fetch {
FETCH;
}
+/* Grab configuration txt blocks */
$urlmappings = varnish_get_url_mappings_txt();
$backends = get_backend_config_txt();
$backends .= get_lb_directors_config_txt();
-
+/* Start to build varnish default.vcl configurationf file */
$varnish_config_file = <<<EOF
# Varnish configuration file
# Automatically generated by the pfSense package system
@@ -343,6 +346,7 @@ EOF;
varnish_sync_on_changes();
}
+/* Uses XMLRPC to synchronize the changes to a remote node */
function varnish_sync_on_changes() {
global $g, $config;
log_error("[varnish] varnish_xmlrpc_sync.php is starting.");
@@ -372,6 +376,7 @@ function varnish_sync_on_changes() {
log_error("[varnish] varnish_xmlrpc_sync.php is ending.");
}
+/* Do the actual XMLRPC sync */
function varnish_do_xmlrpc_sync($sync_to_ip, $password) {
global $config, $g;