Sha256: bef3cafd229db6efb9f357aa9533b067d8a26a5315e925e96cfa8bd94d784e12
Contents?: true
Size: 1.4 KB
Versions: 5
Compression:
Stored size: 1.4 KB
Contents
God.watch do |w| w.name = "varnish" w.group = "proxy" w.autostart = false w.start = "/etc/init.d/varnish start" w.stop = "/etc/init.d/varnish stop" w.restart = "/etc/init.d/varnish restart" w.pid_file = "/var/run/varnishd.pid" w.grace = 10.seconds default_configurations(w) # I'm not sure if it's very useful to monitor the varnishd memory usage, # because it writes the pid of the varnishd parent process in it's pid file, # so I assume that's what god is monitoring, and the varnishd parent starts # a child process to do the real work. # Also, the child process allocates all cache storage with malloc, so the # VSS size can get very large and depends on the amount of storage # configured. It relies on the OS to page unused portions to disk, but at # the moment we don't have much swap configured (just using the defaults # from Eric Hammond's base image). restart_if_resource_hog(w, :memory_usage => 100.megabytes, :cpu_usage => 50.percent) end God.watch do |w| w.name = "varnishncsa" w.group = "proxy" w.autostart = false w.start = "/etc/init.d/varnishncsa start" w.stop = "/etc/init.d/varnishncsa stop" w.restart = "/etc/init.d/varnishncsa restart" w.pid_file = "/var/run/varnishncsa.pid" w.grace = 10.seconds default_configurations(w) restart_if_resource_hog(w, :memory_usage => 100.megabytes, :cpu_usage => 50.percent) end
Version data entries
5 entries across 5 versions & 3 rubygems