mirror of
https://github.com/fatedier/frp.git
synced 2025-06-17 17:18:21 +00:00
Compare commits
3 Commits
38fee20ed5
...
40d5d896f2
Author | SHA1 | Date | |
---|---|---|---|
|
40d5d896f2 | ||
|
885278c045 | ||
|
b4474ec619 |
20
Makefile
20
Makefile
@ -2,40 +2,52 @@ export PATH := $(PATH):`go env GOPATH`/bin
|
||||
export GO111MODULE=on
|
||||
LDFLAGS := -s -w
|
||||
|
||||
.PHONY: all
|
||||
all: env fmt build
|
||||
|
||||
.PHONY: build
|
||||
build: frps frpc
|
||||
|
||||
.PHONY: env
|
||||
env:
|
||||
@go version
|
||||
|
||||
# compile assets into binary file
|
||||
.PHONY: file
|
||||
file:
|
||||
rm -rf ./assets/frps/static/*
|
||||
rm -rf ./assets/frpc/static/*
|
||||
cp -rf ./web/frps/dist/* ./assets/frps/static
|
||||
cp -rf ./web/frpc/dist/* ./assets/frpc/static
|
||||
|
||||
.PHONY: fmt
|
||||
fmt:
|
||||
go fmt ./...
|
||||
|
||||
.PHONY: fmt-more
|
||||
fmt-more:
|
||||
gofumpt -l -w .
|
||||
|
||||
.PHONY: gci
|
||||
gci:
|
||||
gci write -s standard -s default -s "prefix(github.com/fatedier/frp/)" ./
|
||||
|
||||
.PHONY: vet
|
||||
vet:
|
||||
go vet ./...
|
||||
|
||||
.PHONY: frps
|
||||
frps:
|
||||
env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags frps -o bin/frps ./cmd/frps
|
||||
|
||||
.PHONY: frpc
|
||||
frpc:
|
||||
env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags frpc -o bin/frpc ./cmd/frpc
|
||||
|
||||
.PHONY: test
|
||||
test: gotest
|
||||
|
||||
.PHONY: gotest
|
||||
gotest:
|
||||
go test -v --cover ./assets/...
|
||||
go test -v --cover ./cmd/...
|
||||
@ -43,12 +55,15 @@ gotest:
|
||||
go test -v --cover ./server/...
|
||||
go test -v --cover ./pkg/...
|
||||
|
||||
.PHONY: e2e
|
||||
e2e:
|
||||
./hack/run-e2e.sh
|
||||
|
||||
.PHONY: e2e-trace
|
||||
e2e-trace:
|
||||
DEBUG=true LOG_LEVEL=trace ./hack/run-e2e.sh
|
||||
|
||||
.PHONY: e2e-compatibility-last-frpc
|
||||
e2e-compatibility-last-frpc:
|
||||
if [ ! -d "./lastversion" ]; then \
|
||||
TARGET_DIRNAME=lastversion ./hack/download.sh; \
|
||||
@ -56,6 +71,7 @@ e2e-compatibility-last-frpc:
|
||||
FRPC_PATH="`pwd`/lastversion/frpc" ./hack/run-e2e.sh
|
||||
rm -r ./lastversion
|
||||
|
||||
.PHONY: e2e-compatibility-last-frps
|
||||
e2e-compatibility-last-frps:
|
||||
if [ ! -d "./lastversion" ]; then \
|
||||
TARGET_DIRNAME=lastversion ./hack/download.sh; \
|
||||
@ -63,8 +79,10 @@ e2e-compatibility-last-frps:
|
||||
FRPS_PATH="`pwd`/lastversion/frps" ./hack/run-e2e.sh
|
||||
rm -r ./lastversion
|
||||
|
||||
.PHONY: alltest
|
||||
alltest: vet gotest e2e
|
||||
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f ./bin/frpc
|
||||
rm -f ./bin/frps
|
||||
|
@ -82,6 +82,7 @@ frp also offers a P2P connect mode.
|
||||
* [Client Plugins](#client-plugins)
|
||||
* [Server Manage Plugins](#server-manage-plugins)
|
||||
* [SSH Tunnel Gateway](#ssh-tunnel-gateway)
|
||||
* [Releated Projects](#releated-projects)
|
||||
* [Contributing](#contributing)
|
||||
* [Donation](#donation)
|
||||
* [GitHub Sponsors](#github-sponsors)
|
||||
@ -1244,6 +1245,11 @@ frpc tcp --proxy_name "test-tcp" --local_ip 127.0.0.1 --local_port 8080 --remote
|
||||
|
||||
Please refer to this [document](/doc/ssh_tunnel_gateway.md) for more information.
|
||||
|
||||
## Releated Projects
|
||||
|
||||
* [gofrp/plugin](https://github.com/gofrp/plugin) - A repository for frp plugins that contains a variety of plugins implemented based on the frp extension mechanism, meeting the customization needs of different scenarios.
|
||||
* [gofrp/tiny-frpc](https://github.com/gofrp/tiny-frpc) - A lightweight version of the frp client (around 3.5MB at minimum) implemented using the ssh protocol, supporting some of the most commonly used features, suitable for devices with limited resources.
|
||||
|
||||
## Contributing
|
||||
|
||||
Interested in getting involved? We would like to help you!
|
||||
|
11
README_zh.md
11
README_zh.md
@ -72,7 +72,12 @@ frp 是一个免费且开源的项目,我们欢迎任何人为其开发和进
|
||||
* 贡献代码请提交 PR 至 dev 分支,master 分支仅用于发布稳定可用版本。
|
||||
* 如果你有任何其他方面的问题或合作,欢迎发送邮件至 fatedier@gmail.com 。
|
||||
|
||||
**提醒:和项目相关的问题最好在 [issues](https://github.com/fatedier/frp/issues) 中反馈,这样方便其他有类似问题的人可以快速查找解决方法,并且也避免了我们重复回答一些问题。**
|
||||
**提醒:和项目相关的问题请在 [issues](https://github.com/fatedier/frp/issues) 中反馈,这样方便其他有类似问题的人可以快速查找解决方法,并且也避免了我们重复回答一些问题。**
|
||||
|
||||
## 关联项目
|
||||
|
||||
* [gofrp/plugin](https://github.com/gofrp/plugin) - frp 插件仓库,收录了基于 frp 扩展机制实现的各种插件,满足各种场景下的定制化需求。
|
||||
* [gofrp/tiny-frpc](https://github.com/gofrp/tiny-frpc) - 基于 ssh 协议实现的 frp 客户端的精简版本(最低约 3.5MB 左右),支持常用的部分功能,适用于资源有限的设备。
|
||||
|
||||
## 赞助
|
||||
|
||||
@ -93,7 +98,3 @@ frp 是一个免费且开源的项目,我们欢迎任何人为其开发和进
|
||||
如果您想了解更多 frp 相关技术以及更新详解,或者寻求任何 frp 使用方面的帮助,都可以通过微信扫描下方的二维码付费加入知识星球的官方社群:
|
||||
|
||||

|
||||
|
||||
### 微信支付捐赠
|
||||
|
||||

|
||||
|
Loading…
x
Reference in New Issue
Block a user