{"id":119,"date":"2022-01-24T01:24:32","date_gmt":"2022-01-23T17:24:32","guid":{"rendered":"https:\/\/www.addgm.com\/?p=119"},"modified":"2022-01-24T01:24:54","modified_gmt":"2022-01-23T17:24:54","slug":"%e5%86%85%e7%bd%91%e7%a9%bf%e9%80%8f%e5%b7%a5%e5%85%b7-frp","status":"publish","type":"post","link":"https:\/\/www.addgm.com\/index.php\/2022\/01\/24\/%e5%86%85%e7%bd%91%e7%a9%bf%e9%80%8f%e5%b7%a5%e5%85%b7-frp\/","title":{"rendered":"\u5185\u7f51\u7a7f\u900f\u5de5\u5177 FRP"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">\u642d\u5efa\u914d\u7f6e\u6559\u7a0b<\/h2>\n\n\n\n<h2 class=\"wp-block-heading\">frps.ini<\/h2>\n\n\n\n<p>\u66f4\u65b0\u914d\u7f6e\u6587\u4ef6\uff1afrps.ini \u6216\u8005frps_full.ini<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-ini\">[common]\nbind_port = 7000 # \u9ed8\u8ba4\u76d1\u542c\u7aef\u53e3\uff0c\u53ef\u4ee5\u4fee\u6539\nvhost_http_port = 80 # http\u670d\u52a1\u9ed8\u8ba4\u7aef\u53e3\uff0c\u53ef\u4ee5\u4fee\u6539\nvhost_https_port = 443 # https\u670d\u52a1\u9ed8\u8ba4\u7aef\u53e3\uff0c\u53ef\u4ee5\u4fee\u6539\n\ntoken = xxxxx # \u7528\u4e8e\u670d\u52a1\u7aef\u548c\u5ba2\u6237\u7aef\u7684\u9a8c\u8bc1\uff0c\u81ea\u884c\u914d\u7f6e\n\ndashboard_port = 7500 # dashboard\u914d\u7f6e\u4fe1\u606f\uff0c\u5efa\u8bae\u914d\u7f6e\ndashboard_user = admin\ndashboard_pwd = admin\nenable_prometheus = true\n\nlog_file = \/var\/log\/frps.log # \u65e5\u5fd7\u4fe1\u606f\u914d\u7f6e\uff0c\u53ef\u9009\nlog_level = info\nlog_max_days = 3<\/code><\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">\u8bbe\u7f6e\u540e\u53f0\u542f\u52a8\u670d\u52a1<\/h2>\n\n\n\n<p>\u521b\u5efa\u5e76\u6253\u5f00\u6587\u4ef6\uff1afrps.service<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-bash\">\/etc\/systemd\/system\/frps.service<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-\">[Unit]\n# \u670d\u52a1\u540d\u79f0\uff0c\u53ef\u81ea\u5b9a\u4e49\nDescription = frp server\nAfter = network.target syslog.target\nWants = network.target\n\n[Service]\nType = simple # \u542f\u52a8frps\u7684\u547d\u4ee4\uff0c\u9700\u4fee\u6539\u4e3a\u60a8\u7684frps\u7684\u5b89\u88c5\u8def\u5f84\nExecStart = \/root\/frp_0.44.0_linux_amd64\/frps -c \/root\/frp_0.44.0_linux_amd64\/frps.ini\n\n[Install] WantedBy = multi-user.target<\/code><\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><\/blockquote>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">\u76f8\u5173\u547d\u4ee4<\/h2>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-bash\">systemctl start frps    # \u542f\u52a8\u670d\u52a1\nsystemctl restart frps    # \u91cd\u542f\u670d\u52a1\nsystemctl stop frps    # \u505c\u6b62\u670d\u52a1\nsystemctl status frps    # \u67e5\u8be2\u72b6\u6001\nsystemctl enable frps    # \u8bbe\u7f6e\u5f00\u673a\u81ea\u542f\u52a8\nsystemctl disable frps    # \u5220\u9664\u5f00\u673a\u81ea\u542f\u52a8\n\njournalctl -u frps -f    # \u67e5\u8be2\u8fd0\u884c\u65e5\u5fd7<\/code><\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>\u642d\u5efa\u914d\u7f6e\u6559\u7a0b frps.ini \u66f4\u65b0\u914d\u7f6e\u6587\u4ef6\uff1afrps.ini \u6216\u8005frps_full.ini \u8bbe\u7f6e\u540e\u53f0\u542f\u52a8\u670d\u52a1 \u521b\u5efa\u5e76\u6253\u5f00\u6587\u4ef6\uff1a &#8230;<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[3],"class_list":["post-119","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-3"],"_links":{"self":[{"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/posts\/119","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/comments?post=119"}],"version-history":[{"count":1,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/posts\/119\/revisions"}],"predecessor-version":[{"id":120,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/posts\/119\/revisions\/120"}],"wp:attachment":[{"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/media?parent=119"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/categories?post=119"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.addgm.com\/index.php\/wp-json\/wp\/v2\/tags?post=119"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}