PageRenderTime 18ms CodeModel.GetById 11ms RepoModel.GetById 0ms app.codeStats 0ms

/silverlining/server-root/etc/default/varnish

https://bitbucket.org/ianb/silverlining/
#! | 97 lines | 86 code | 11 blank | 0 comment | 0 complexity | 20ba6b6612f26157263941d06be03087 MD5 | raw file
Possible License(s): GPL-2.0
  1. # Configuration file for varnish
  2. #
  3. # /etc/init.d/varnish expects the variables $DAEMON_OPTS, $NFILES and $MEMLOCK
  4. # to be set from this shell script fragment.
  5. #
  6. # Maximum number of open files (for ulimit -n)
  7. NFILES=131072
  8. # Maximum locked memory size (for ulimit -l)
  9. # Used for locking the shared memory log in memory. If you increase log size,
  10. # you need to increase this number as well
  11. MEMLOCK=82000
  12. # Default varnish instance name is the local nodename. Can be overridden with
  13. # the -n switch, to have more instances on a single server.
  14. INSTANCE=$(uname -n)
  15. # This file contains 4 alternatives, please use only one.
  16. ## Alternative 1, Minimal configuration, no VCL
  17. #
  18. # Listen on port 6081, administration on localhost:6082, and forward to
  19. # content server on localhost:8080. Use a 1GB fixed-size cache file.
  20. #
  21. # DAEMON_OPTS="-a :6081 \
  22. # -T localhost:6082 \
  23. # -b localhost:8080 \
  24. # -u varnish -g varnish \
  25. # -s file,/var/lib/varnish/$INSTANCE/varnish_storage.bin,1G"
  26. ## Alternative 2, Configuration with VCL
  27. #
  28. # Listen on port 6081, administration on localhost:6082, and forward to
  29. # one content server selected by the vcl file, based on the request. Use a 1GB
  30. # fixed-size cache file.
  31. #
  32. DAEMON_OPTS="-a :80 \
  33. -T localhost:6082 \
  34. -f /etc/varnish/default.vcl \
  35. -s file,/var/lib/varnish/$INSTANCE/varnish_storage.bin,1G"
  36. ## Alternative 3, Advanced configuration
  37. #
  38. # See varnishd(1) for more information.
  39. #
  40. # # Main configuration file. You probably want to change it :)
  41. # VARNISH_VCL_CONF=/etc/varnish/default.vcl
  42. #
  43. # # Default address and port to bind to
  44. # # Blank address means all IPv4 and IPv6 interfaces, otherwise specify
  45. # # a host name, an IPv4 dotted quad, or an IPv6 address in brackets.
  46. # VARNISH_LISTEN_ADDRESS=
  47. # VARNISH_LISTEN_PORT=6081
  48. #
  49. # # Telnet admin interface listen address and port
  50. # VARNISH_ADMIN_LISTEN_ADDRESS=127.0.0.1
  51. # VARNISH_ADMIN_LISTEN_PORT=6082
  52. #
  53. # # The minimum number of worker threads to start
  54. # VARNISH_MIN_THREADS=1
  55. #
  56. # # The Maximum number of worker threads to start
  57. # VARNISH_MAX_THREADS=1000
  58. #
  59. # # Idle timeout for worker threads
  60. # VARNISH_THREAD_TIMEOUT=120
  61. #
  62. # # Cache file location
  63. # VARNISH_STORAGE_FILE=/var/lib/varnish/$INSTANCE/varnish_storage.bin
  64. #
  65. # # Cache file size: in bytes, optionally using k / M / G / T suffix,
  66. # # or in percentage of available disk space using the % suffix.
  67. # VARNISH_STORAGE_SIZE=1G
  68. #
  69. # # Backend storage specification
  70. # VARNISH_STORAGE="file,${VARNISH_STORAGE_FILE},${VARNISH_STORAGE_SIZE}"
  71. #
  72. # # Default TTL used when the backend does not specify one
  73. # VARNISH_TTL=120
  74. #
  75. # # DAEMON_OPTS is used by the init script. If you add or remove options, make
  76. # # sure you update this section, too.
  77. # DAEMON_OPTS="-a ${VARNISH_LISTEN_ADDRESS}:${VARNISH_LISTEN_PORT} \
  78. # -f ${VARNISH_VCL_CONF} \
  79. # -T ${VARNISH_ADMIN_LISTEN_ADDRESS}:${VARNISH_ADMIN_LISTEN_PORT} \
  80. # -t ${VARNISH_TTL} \
  81. # -w ${VARNISH_MIN_THREADS},${VARNISH_MAX_THREADS},${VARNISH_THREAD_TIMEOUT} \
  82. # -s ${VARNISH_STORAGE}"
  83. #
  84. ## Alternative 4, Do It Yourself
  85. #
  86. # DAEMON_OPTS=""