Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

功能建议: 建议添加一键安装脚本(主要方便部署linux服务器) #1058

Closed
snowdream opened this issue Jan 23, 2019 · 19 comments
Labels

Comments

@snowdream
Copy link

功能建议: 建议添加一键安装脚本(主要方便部署linux服务器)

@yunnl
Copy link

yunnl commented Jan 24, 2019

解压 设置权限 运行,这种还要一键脚本?

@fatedier
Copy link
Owner

可以提供一些规范化的例如支持 systemctl 的配置,TODO

@fatedier fatedier added the todo label Jan 24, 2019
@flykarry
Copy link

我觉着这个已经属于非常简单的东西了

@catchfishday
Copy link

可以像ss、v2ray写个sh脚本,安装、更新、重启、开机启动等服务,这样更容易上手

@lyin888
Copy link

lyin888 commented Jan 29, 2019

可以像SS,v2ray写个SH脚本,安装,更新,重启,开机启动等服务,这样更容易上手

使用supervisor来守护frps

sudo apt-get update

sudo apt-get install supervisor

vi /etc/supervisor/conf.d/frps.conf

[program:frps]
command = /root/frps/frps -c /root/frps/frps.ini # frps存放路径
autostart = true

重启supervisor

sudo systemctl restart supervisor

查看supervisor运行状态

sudo supervisorctl status

@smoryan
Copy link

smoryan commented Jan 30, 2019

[Unit]
Description=Frp Server Daemon
After=syslog.target network.target
Wants=network.target

[Service]
Type=simple
ExecStart=/usr/bin/frps -c /etc/frps.ini
ExecStop=/usr/bin/killall frps
#启动失败1分钟后再次启动
RestartSec=1min
KillMode=control-group
#重启控制:总是重启
Restart=always

[Install]
WantedBy=multi-user.target

这个脚本放在# /etc/systemd/system/frps.service
然后 systemctl enable frps.service 即可
配置文件请自己搞掂。。每个人的需求都不同
@fatedier 这个systemctl配置应该足够简单通用了吧

@MvsCode
Copy link

MvsCode commented Feb 8, 2019

Frps 一键安装脚本&管理脚本 for Linux,frp:v0.23.3 https://github.com/MvsCode/frp-onekey

@a-wing
Copy link
Contributor

a-wing commented Mar 20, 2019

为什么不考虑把软件推到 linux 发行版的官方仓库中

archlinux 的 AUR 上有人打了这个包
不过按规范这种应该算 bin 包

https://aur.archlinux.org/packages/frp/

目前 archlinuxcn 软件仓库中有一共有三个 frp 的包

最近准备合并成一个然后 split package

archlinuxcn/repo#1083

@fatedier
Copy link
Owner

@a-wing 不是很了解相关的东西,你能提供一些帮助?

a-wing added a commit to a-wing/frp that referenced this issue Mar 21, 2019
Ref fatedier#1058
Ref https://aur.archlinux.org/packages/frp/

Co-authored-by: vimsucks <dev@vimsucks.com>
@kantkong
Copy link

参考这个 https://github.com/clangcn/onekey-install-shell

@deadlineOvO
Copy link

话说日志的话

会在相关的服务管理程序提供的日志功能上吗

@chronicom
Copy link

为什么不考虑把软件推到 linux 发行版的官方仓库中

archlinux 的 AUR 上有人打了这个包
不过按规范这种应该算 bin 包

https://aur.archlinux.org/packages/frp/

目前 archlinuxcn 软件仓库中有一共有三个 frp 的包

最近准备合并成一个然后 split package

archlinuxcn/repo#1083

frps.service 中
User=nobody
好像在ubuntu 下有问题 nobody 没有绑定80端口的权限

@a-wing
Copy link
Contributor

a-wing commented Apr 15, 2019

好像在ubuntu 下有问题 nobody 没有绑定80端口的权限

正常的发行版。 1024 以下的端口当然都不行。

特权端口 你自己用 nginxiptables 转一下。

@deadlineOvO
Copy link

好像在ubuntu 下有问题 nobody 没有绑定80端口的权限

正常的发行版。 1024 以下的端口当然都不行。

特权端口 你自己用 nginxiptables 转一下。

不过为什么要用 nobody 用户来启动 frp 呢?

@Athenacle
Copy link

话说为啥没有官方docker啊,去DockerHub逛了一圈,找了个xddxdd/frps两个月前更新的。。

客户端使用的时候一直是说[W] [service.go:82] login to server failed: session shutdown

服务器端[D] [service.go:304] Accept new mux stream error: invalid protocol version

一看服务器版本0.22,客户端版本0.26。。不得不自己FROM scratch做一个。。为啥不能向后兼容

@snowdream
Copy link
Author

snowdream commented Jun 17, 2019

已经封装了Docker镜像,支持amd64, arm32v6, arm32v7, arm64v8, i386。

frp

Docker Image packaging for Frp.

(amd64, arm32v6, arm32v7, arm64v8, i386)

Usage

start frps

docker run  --network host -d -v /etc/frp/frps.ini:/etc/frp/frps.ini --name frps snowdreamtech/frps

start frpc

docker run  --network host -d -v /etc/frp/frpc.ini:/etc/frp/frpc.ini --name frpc snowdreamtech/frpc

Quick reference

  • Where to file issues:

https://github.com/snowdreamtech/frp/issues

  • Maintained by:

snowdream sn0wdr1am@icloud.com

frpc:

amd64, arm32v6, arm32v7, arm64v8, i386

frps:

amd64, arm32v6, arm32v7, arm64v8, i386

  • Supported Tags:

Frps

Frpc

License

Apache 2.0

@deadlineOvO
Copy link

可以在这里提交相关的东西了

@ttimasdf
Copy link

ttimasdf commented Sep 3, 2020

我是从google过来的,简单搜一下能搜到好多……给后来的人汇总一下。
没营养的: #1302 #902 #1474
一些解决方案: #1058 (本贴)
作者说明不维护service脚本(包括Dockerfile)的原因: #1291 (comment)

建议加到项目FAQ里。


PS: 我平时用的Dockerfile,甚至不需要Alpine XD

FROM scratch
ARG ver=0.33.0
COPY ./frp_${ver}_linux_amd64/frps /frps
ENTRYPOINT ["/frps", "-c", "/frps.ini"]

@dzcpy
Copy link

dzcpy commented Jun 24, 2021

建议还是做个 debian 包,直接安装的话还是多少省点事,更新起来也方便

newheaven918 added a commit to newheaven918/Reverse-Proxy that referenced this issue Feb 20, 2024
Ref fatedier/frp#1058
Ref https://aur.archlinux.org/packages/frp/

Co-authored-by: vimsucks <dev@vimsucks.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests