Article directory
Introduction
CuteHttpFileServer/chfs is a free, HTTP protocol file sharing server that can be quickly accessed using a browser. It has the following characteristics:
- Single file, no other files required for core functionality
- Cross-platform operation, supports mainstream platforms: Windows, Linux and Mac
- Simple interface, easy to use
- Support account permission control and address filtering
Highly recommended: A very easy-to-use file sharing tool, simple to deploy, simple to manage, and simple to use. It can meet all the functions you want. It can be used as a product library for the company's software products.
download link
Official website address: http://iscute.cn/chfs
Description: The official website also has detailed deployment instructions. You can refer to the deployment in combination with this document.
Linux version installation steps
1. Download the chfs package
wget http://iscute.cn/tar/chfs/1.10/chfs-linux-amd64-1.10.zip
2. Unzip the installation package to /opt/
the directory
unzip chfs-linux-arm64-2.0.zip -d /opt/
3. Add executable permissions to the chfs command in the opt directory
chmod +x /opt/chfs
4. Create configuration file
vi /opt/chfs.cnf
Write:
#---------------------------------------
# 请注意:
# 1,如果不存在键或对应值为空,则不影响对应的配置
# 2,配置项的值,语法如同其对应的命令行参数
#---------------------------------------
# 监听端口
port=9042
# 共享根目录,通过字符'|'进行分割
# 注意:
# 1,带空格的目录须用引号包住,如 path="c:\a uply name\folder"
# 2,可配置多个path,分别对应不同的目录
path=/data
# IP地址过滤
allow=
#----------------- 账户控制规则 -------------------
# 注意:该键值可以同时存在多个,你可以将每个用户的访问规则写成一个rule,这样比较清晰,如:
# rule=::
# rule=root:123456:RW
# rule=readonlyuser:123456:R
rule=::
rule=admin:admin@123:R:1:R
rule=bairanping:admin@123:R:1:RW
# 用户操作日志存放目录,默认为空
# 如果赋值为空,表示禁用日志
log=/opt/chfs.log
# 网页标题
html.title=********软件产品库
# 网页顶部的公告板。可以是文字,也可以是HTML标签,此时,需要适用一对``(反单引号,通过键盘左上角的ESC键下面的那个键输出)来包住所有HTML标签。几个例子:
# 1,html.notice=内部资料,请勿传播
# 2,html.notice=`<img src="https://mat1.gtimg.com/pingjs/ext2020/qqindex2018/dist/img/qq_logo_2x.png" width="100%"/>`
# 3,html.notice=`<div style="background:black;color:white"><p>目录说明:</p><ul>一期工程:一期工程资料目录</ul><ul>二期工程:二期工程资料目录</ul></div>`
html.notice=您以登录********软件产品库,注意:内部资料,请勿传播!!!
# 是否启用图片预览(网页中显示图片文件的缩略图),true表示开启,false为关闭。默认开启
image.preview=
# 下载目录策略。disable:禁用; leaf:仅限叶子目录的下载; enable或其他值:不进行限制。
# 默认值为 enable
folder.download=leaf
#-------------- 设置生效后启用HTTPS,注意监听端口设置为443-------------
# 指定certificate文件
ssl.cert=
# 指定private key文件
ssl.key=
# 设置会话的生命周期,单位:分钟,默认为30分钟
session.timeout=
4. Start running
Operation mode one:
#下载依赖工具
yum -y install screen
# 运行
screen -dmS chfs ./chfs --file="/opt/chfs.cnf"
Operation mode two:
# 运行
./chfs --file="/home/chfs/chfs.cnf" &
access test
Log in
Main interface