我正在尝试在 ubuntu 16.04 上安装清漆,
我读了几篇文章都没有工作。从我读到的内容来看,从 ubuntu 15.04 开始,配置 varnish 的方式发生了变化(因为 systemd)。
现在我有一个真正的烂摊子,不起作用:
/etc/default/varnish :
DAEMON_OPTS="-a :80 \
-T localhost:6082 \
-f /etc/varnish/default.vcl \
-S /etc/varnish/secret \
-s malloc,256m"
Run Code Online (Sandbox Code Playgroud)
/etc/varnish/default.vcl(通常它指向一个指向 127.0.0 和端口 8080 的主机,但出于调试目的,我将其修改为外部域) vcl 4.0;
# Default backend definition. Set this to point to your content server.
backend default {
.host = "www.varnish-cache.org";
.port = "80";
}
Run Code Online (Sandbox Code Playgroud)
/etc/apache2/ports.conf
Listen 8080
Run Code Online (Sandbox Code Playgroud)
grep -R 'ExecStart=/usr/sbin/varnishd' /etc/
/etc/systemd/system/varnish.service:ExecStart=/usr/sbin/varnishd -j unix,user=vcache -F -a :80 -T localhost:6082 -f /etc/varnish/default.vcl -S /etc/varnish/secret -s malloc,256m
/etc/systemd/system/varnish.service.d/customexec.conf:ExecStart=/usr/sbin/varnishd -a …
Run Code Online (Sandbox Code Playgroud)