summaryrefslogtreecommitdiffhomepage
path: root/example.conf.hcl
blob: e6f9d5168283dd62fee7de79ddc85411724ab192 (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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
server http {
    host = "127.0.0.1"
    port = 8000

    proxy a {
        from {
            host = "a.localhost"
        }
        to {
            host = "127.0.0.1"
            port = 8001
        }
    }

    proxy b {
        from {
            path = "/b/"
        }
        to {
            host = "127.0.0.1"
            port = 8002
        }
        auth basic {
            realm = "basic auth b"
            credential_file = "example.htpasswd"
            # user: nsfisis
            # password: password
        }
    }

    proxy c {
        from {
            host = "c.localhost"
            path = "/c/"
        }
        to {
            host = "127.0.0.1"
            port = 8003
        }
    }
}