cloudreve私有云盘配置后台运行

jupiter
2021-02-28 / 0 评论 / 1,737 阅读 / 正在检测是否收录...
温馨提示:
本文最后更新于2021年12月07日,已超过962天没有更新,若内容或图片失效,请留言反馈。

cloudreve私有云盘配置后台运行

在/usr/lib/systemd/system目录下创建一个服务cloudreve.service

sudo vim /etc/systemd/system/cloudreve.service

输入如下内容:

[Unit]
Description=Cloudreve
Documentation=https://docs.cloudreve.org

[Service]
TimeoutStartSec=0
ExecStart=/data/cloudreve/cloudreve
ExecReload=/bin/kill -HUP $MAINPID
KillMode=process
Restart=on-failure
RestartSec=5s

[Install]
WantedBy=multi-user.target

更新重启服务

# 更新配置
systemctl daemon-reload

# 启动服务
systemctl start cloudreve

# 设置开机启动
systemctl enable cloudreve

管理命令

# 启动服务
systemctl start cloudreve

# 停止服务
systemctl stop cloudreve

# 重启服务
systemctl restart cloudreve

# 查看状态
systemctl status cloudreve

参考资料

  1. cloudreve私有云盘配置后台运行:https://blog.csdn.net/longzhoufeng/article/details/108958091
0

评论 (0)

打卡
取消