# Configuration file for varnish
# See varnishd(1) for more information.

# Maximum number of open files (for ulimit -n)
# Open files (usually 1024, which is way too small for varnish)
NFILES=131072

# Maximum locked memory size (for ulimit -l)
# Used for locking the shared memory log in memory.  If you increase log size,
# you need to increase this number as well
MEMLOCK=82000

# Main configuration file. You probably want to change it :)
VARNISH_VCL_CONF=/etc/varnish/default.vcl

# Default varnish instance name is the local nodename.  Can be overridden with
# the -n switch, to have more instances on a single server.
INSTANCE=$(uname -n)

# Name of this system / path to spool file
VARNISH_NAME=/var/run/varnish/$INSTANCE

# Specifies the name of an unprivileged user/group to which the child process should
# switch before it starts accepting connections.
VARNISH_USER=varnish
VARNISH_GROUP=varnish

# Default address and port to bind to
# Blank address means all IPv4 and IPv6 interfaces, otherwise specify
# a host name, an IPv4 dotted quad, or an IPv6 address in brackets.
VARNISH_LISTEN_ADDRESS=127.0.0.1
VARNISH_LISTEN_PORT=6081

# Telnet admin interface listen address and port
VARNISH_ADMIN_LISTEN_ADDRESS=127.0.0.1
VARNISH_ADMIN_LISTEN_PORT=6082

# The minimum number of worker threads to start
VARNISH_MIN_THREADS=1

# The Maximum number of worker threads to start
VARNISH_MAX_THREADS=1000

# Idle timeout for worker threads
VARNISH_THREAD_TIMEOUT=120

# Any custom option you want to pass to varnishd.
# As it is passed last option to varnishd, it can override the earlier values.
VARNISH_OPTS=""

# Syntax: param=value [param=value]
# Set the parameters specified by param to the specified value.
# See Run-Time Parameters section of varnishd(1) for a list of parameters.
#VARNISH_PARAMS="cli_timeout=10 thread_pools=4"

# Cache file location
VARNISH_STORAGE_FILE=/var/lib/varnish/varnish_storage.bin

# Cache file size: in bytes, optionally using k / M / G / T suffix,
# or in percentage of available disk space using the % suffix.
VARNISH_STORAGE_SIZE=1G

# Backend storage specification
VARNISH_STORAGE="file,${VARNISH_STORAGE_FILE},${VARNISH_STORAGE_SIZE}"

# Default TTL used when the backend does not specify one
VARNISH_TTL=120
