The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
---
% my $root = dir "@{[ home ]}/var/run";
% $root->mkpath(0,0700);

url: http://<%= $host %>:<%= $port %>
start_mode:
  - hypnotoad
  - nginx

nginx:
  args: -p <%= $root %>/nginx.<%= $port %>/
  autogen:
    filename: <%= $root %>/nginx.<%= $port %>/conf/nginx.conf
    content: |
      worker_processes auto;
      events {
        use epoll;
        worker_connections 4096;
      }
      http {
        server {
          listen <%= $host %>:<%= $port %>;
          location / {
            proxy_pass http://127.0.0.1:<%= $port %>;
            proxy_http_version 1.1;
            proxy_read_timeout 300;
          }
        }
      }

hypnotoad:
  listen:
    - http://127.0.0.1:<%= $port %>
  pid_file: <%= $root %>/hypnotoad.<%= $port %>.pid