@marcel91200 / caddy Mirror · read-only
Fork 0

Fast and extensible multi-platform HTTP/1-2-3 web server with automatic HTTPS

Mirrored from https://github.com/Slazee/caddy.git

Synced Nov 11, 01:00 UTC

master
caddyfiletest 71 lines 1.02 KB
Raw
1 localhost
2
3 respond "hello from localhost"
4 tls {
5 client_auth {
6 mode request
7 trust_pool file {
8 pem_file ../caddy.ca.cer
9 }
10 }
11 }
12 ----------
13 {
14 "apps": {
15 "http": {
16 "servers": {
17 "srv0": {
18 "listen": [
19 ":443"
20 ],
21 "routes": [
22 {
23 "match": [
24 {
25 "host": [
26 "localhost"
27 ]
28 }
29 ],
30 "handle": [
31 {
32 "handler": "subroute",
33 "routes": [
34 {
35 "handle": [
36 {
37 "body": "hello from localhost",
38 "handler": "static_response"
39 }
40 ]
41 }
42 ]
43 }
44 ],
45 "terminal": true
46 }
47 ],
48 "tls_connection_policies": [
49 {
50 "match": {
51 "sni": [
52 "localhost"
53 ]
54 },
55 "client_authentication": {
56 "ca": {
57 "pem_files": [
58 "../caddy.ca.cer"
59 ],
60 "provider": "file"
61 },
62 "mode": "request"
63 }
64 },
65 {}
66 ]
67 }
68 }
69 }
70 }
71 }