Skip to content

Commit 515e66c

Browse files
committed
Add the "frp" note.
1 parent 12020e3 commit 515e66c

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

content/notes/frp.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
+++
2+
title = "frp"
3+
+++
4+
5+
*frp* is a fast reverse proxy that allows you to expose a local server located behind a NAT or firewall to the Internet. It currently supports TCP and UDP, as well as HTTP and HTTPS protocols, enabling requests to be forwarded to internal services via domain name.
6+
7+
Links:
8+
9+
- [Source code](https://github.com/fatedier/frp)
10+
11+
## Example
12+
13+
The following is an example of making a WebDAV server hosted on the client's hardware in a home network with dynamic IP available to the world through HTTP via an *frp* proxy running on the server.
14+
15+
One can also add a TLS termination proxy in the mix to secure the connection.
16+
17+
Server configuration:
18+
19+
```toml
20+
# /etc/frp/frps.toml
21+
22+
bindAddr = "0.0.0.0"
23+
bindPort = 7000
24+
vhostHTTPPort = 80
25+
auth.token = "TOKEN"
26+
subDomainHost = "frp.example.com"
27+
```
28+
29+
Client configuration:
30+
31+
```toml
32+
# /etc/frp/frpc.toml
33+
34+
user = "laptop"
35+
serverAddr = "frp.example.com"
36+
serverPort = 7000
37+
loginFailExit = false
38+
39+
auth.method = "token"
40+
auth.token = "TOKEN"
41+
42+
[[proxies]]
43+
name = "webdav"
44+
type = "http"
45+
localPort = 4918
46+
subdomain = "webdav"
47+
```

0 commit comments

Comments
 (0)