您现在的位置是:首页 > 文章详情

Plik —— 临时文件上传系统

日期:2023-02-21点击:611

Plik 是一个以 Golang 编写的可扩展且友好的临时文件上传系统。

主要特点

  • 强大的命令行客户端
  • 易于使用的 Web 用户界面
  • 多数据后端
  • 多个元数据后端
  • 可移除:上传者可以随时删除文件
  • TTL : 自定义到期日期
  • 密码:使用登录名/密码保护上传
  • 评论:添加自定义消息(Markdown 格式)
  • 用户认证:本地/谷歌/OVH
  • 管理员仪表板
  • 服务器端加密
  • ……

安装

从 Release 页面下载安装

要运行 plik,它非常简单:

 $ wget https://github.com/root-gg/plik/releases/download/1.3.1/plik-1.3.1-linux-amd64.tar.gz $ tar xzvf plik-1.3.1-linux-64bits.tar.gz $ cd plik-1.3.1/server $ ./plikd 

现在拥有一个在 http://127.0.0.1:8080 上运行的功能齐全的 Plik 实例。可以编辑 server/plikd.cfg 以根据需要调整配置(端口、ssl、ttl、后端参数等)

从源代码编译

要从源代码编译 plik,需要在系统上安装 golang 和 npm。

首先,通过 go 获取项目和库:

 $ go get github.com/root-gg/plik/server $ cd $GOPATH/src/github.com/root-gg/plik/ 

构建并运行它:

 $ make $ cd server && ./plikd 

客户端

Plik 附带了一个强大的 golang 多平台 cli 客户端(可在 Web 界面中下载):

 Usage: plik [options] [FILE] ... Options: -h --help Show this help -d --debug Enable debug mode -q --quiet Enable quiet mode -o, --oneshot Enable OneShot ( Each file will be deleted on first download ) -r, --removable Enable Removable upload ( Each file can be deleted by anyone at anymoment ) -S, --stream Enable Streaming ( It will block until remote user starts downloading ) -t, --ttl TTL Time before expiration (Upload will be removed in m|h|d) -n, --name NAME Set file name when piping from STDIN --server SERVER Overrides plik url --token TOKEN Specify an upload token --comments COMMENT Set comments of the upload ( MarkDown compatible ) -p Protect the upload with login and password --password PASSWD Protect the upload with login:password ( if omitted default login is "plik" ) -a Archive upload using default archive params ( see ~/.plikrc ) --archive MODE Archive upload using specified archive backend : tar|zip --compress MODE [tar] Compression codec : gzip|bzip2|xz|lzip|lzma|lzop|compress|no --archive-options OPTIONS [tar|zip] Additional command line options -s Encrypt upload usnig default encrypt params ( see ~/.plikrc ) --not-secure Do not encrypt upload regardless of ~/.plikrc configurations --secure MODE Archive upload using specified archive backend : openssl|pgp --cipher CIPHER [openssl] Openssl cipher to use ( see openssl help ) --passphrase PASSPHRASE [openssl] Passphrase or '-' to be prompted for a passphrase --recipient RECIPIENT [pgp] Set recipient for pgp backend ( example : --recipient Bob ) --secure-options OPTIONS [openssl|pgp] Additional command line options --update Update client -v --version Show client version  

 

原文链接:https://www.oschina.net/p/plik
关注公众号

低调大师中文资讯倾力打造互联网数据资讯、行业资源、电子商务、移动互联网、网络营销平台。

持续更新报道IT业界、互联网、市场资讯、驱动更新,是最及时权威的产业资讯及硬件资讯报道平台。

转载内容版权归作者及来源网站所有,本站原创内容转载请注明来源。

文章评论

共有0条评论来说两句吧...

文章二维码

扫描即可查看该文章

点击排行

推荐阅读

最新文章