In this case, having a server that runs a couple of websites with a varnish service configured as well.
Now, on another server I run 2 wp multisites in a LAMP environment + W3TC Cache + APC, and now I want to configure my first server to serve as reverse proxy for it.
and I wondering if this would do it:
acl whitelist {
"localhost";
"127.0.0.1";
"ip server with varnish";
"ip wordpress server";
}
sub vcl_recv {
if ( ! client.ip ~ whitelist) {
error 403 "Access denied";
}
Before starting testing, as I have very little experience with Varnish, I would like to hear your opinion about setting my server VCL's ACL to allow this request from external servers
UPDATE
Just to point it out, Apache responds to 8080 port and Varnish to 80.
default/varnish
DAEMON_OPTS="-a ip-server-1:80 \
-T localhost:6082 \
-f /etc/varnish/main.vcl \
-S /etc/varnish/secret \
-s file,/var/lib/varnish/$INSTANCE/varnish_storage.bin,1G"