[Pkg-varnish-devel] Bug#749272: Bug#749272: varnish doesn't source /etc/default/varnish when started with systemd

Stig Sandbeck Mathisen ssm at debian.org
Mon May 26 07:54:10 UTC 2014


Control: tag -1 + wontfix
Control: severity -1 wishlist

On Sun, May 25, 2014 at 09:23:01PM +0200, Glennie Vignarajah wrote:
> When varnish is started via systemd, it doesn't use configuration from
> /etc/default/varnish (config section: Alternative 2).  In order to use the
> configuration from /etc/default/varnish, varnish.service should include
> "EnvironmentFile=/etc/default/varnish" under [Service] section.

Hello, and thanks for the bug report.

/etc/default/varnish is used by /etc/init.d/varnish exclusively on purpose.

If you want to use /etc/default/varnish on your own, you can override
/lib/systemd/system/varnish.service in /etc/systemd/system/varnish.service, but
I'll recommend you just write the wanted commandline options in
/etc/systemd/system/varnish.service, instead of reading /etc/default/varnish

I've documented this in /etc/default/varnish, please see the top "Note:" in
http://anonscm.debian.org/gitweb/?p=pkg-varnish/pkg-varnish.git;a=blob;f=debian/varnish.default;h=68b7da41555f924a7a984296de6f523683866f40;hb=e8143261b6a3b1f8864890ff43b90585c17115ad

I'll tag this as a "wishlist+wontfix" bug, and keep it open while waiting for
policy around the use of /etc/default from systemd, upstart, and other init
systems to settle.

-- 
Stig Sandbeck Mathisen



More information about the Pkg-varnish-devel mailing list