aboutsummaryrefslogtreecommitdiffstats
path: root/examples/rack-example-config.rb
blob: 083efa5dbd0d2da01897d465d42e71dcecb6ad69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
log "logs/plum.log"
debug false
server_push true
threadpool_size 20 # use 20 threads to process requests (default: 1( = disable))
fallback_legacy "127.0.0.1:8080" # forward if client doesn't support HTTP/2

user "nobody"
group "nobody"

# listeners may be multiple
listener :unix, { path: "/tmp/plum.sock", mode: 600 }
listener :tcp, { hostname: "0.0.0.0", port: 80 }
listener :tls, {
  hostname: "0.0.0.0",
  port: 443,
  certificate: "/path/to/cert", # chained certifcate is acceptable
  certificate_key: "/path/to/key",
  sni: {
    "rhe.jp" => { # SNI, key must be String. If none matches, default certificate (above) is used
      certificate: "/path/to/rhe.jp/cert",
      certificate_key: "/path/to/rhe.jp/key"
    },
  }
}