16.6k stars 开源的本地文件共享传输工具 docker部署教程

Install

First, Install docker with docker-compose.

Then, clone the repository:

复制代码
    git clone https://github.com/RobinLinus/snapdrop.git
    cd snapdrop
    docker-compose up -d

Now point your browser to http://localhost:8080.

  • To restart the containers run docker-compose restart.
  • To stop the containers run docker-compose stop.
  • To debug the NodeJS server run docker logs snapdrop_node_1.

Run locally by pulling image from Docker Hub

Have docker installed, then use the command:

复制代码
    docker pull linuxserver/snapdrop

To run the image, type (if port 8080 is occupied by host use another random port :80):

复制代码
    docker run -d -p 8080:80 linuxserver/snapdrop

PWAs require that the app is served under a correctly set up and trusted TLS endpoint.

The nginx container creates a CA certificate and a website certificate for you. To correctly set the common name of the certificate, you need to change the FQDN environment variable in docker/fqdn.env to the fully qualified domain name of your workstation.

If you want to test PWA features, you need to trust the CA of the certificate for your local deployment. For your convenience, you can download the crt file from http://<Your FQDN>:8080/ca.crt. Install that certificate to the trust store of your operating system.

  • On Windows, make sure to install it to the Trusted Root Certification Authorities store.
  • On MacOS, double click the installed CA certificate in Keychain Access, expand Trust, and select Always Trust for SSL.
  • Firefox uses its own trust store. To install the CA, point Firefox at http://<Your FQDN>:8080/ca.crt. When prompted, select Trust this CA to identify websites and click OK.
  • When using Chrome, you need to restart Chrome so it reloads the trust store (chrome://restart). Additionally, after installing a new cert, you need to clear the Storage (DevTools -> Application -> Clear storage -> Clear site data).

Please note that the certificates (CA and webserver cert) expire after a day. Also, whenever you restart the nginx docker, container new certificates are created.

The site is served on https://<Your FQDN>:443.

Deployment Notes

The client expects the server at http(s)://your.domain/server.

When serving the node server behind a proxy, the X-Forwarded-For header has to be set by the proxy. Otherwise, all clients that are served by the proxy will be mutually visible.

By default, the server listens on port 3000.

For an nginx configuration example, see docker/nginx/default.conf.

参考地址:docs/local-dev.md · AscendKing/snapdrop - Gitee.com

相关推荐
修己xj27 分钟前
让README “活”起来:Readme Typing SVG 介绍与本地化改造实践
开源
ApacheSeaTunnel3 小时前
为什么 Data Ingestion 还没有被 Fivetran/Airbyte 完全解决?
大数据·开源·数据集成·seatunnel·技术分享·数据同步·airbyte·fivetran
程序员吕洞宾3 小时前
开源多维表格SmartTable V1.6:自动化工作流,把重复操作交给系统即可
开源·自动化·github·多维表格·飞书多维表
GitCode官方4 小时前
基于《人工智能 智能体互联》国标的 AIP 开源项目在 AtomGit 正式开源
人工智能·开源·atomgit
极客先躯4 小时前
高级java每日一道面试题-2026年03月30日-实战篇[Docker]-如何监控容器的网络流量?
java·运维·docker·容器·prometheus·高级面试
Waay5 小时前
Linux 三个核心环境变量配置文件、作用域、生效方式完整梳理
linux·运维·学习·云原生·容器
小弥儿6 小时前
GitHub今日热榜 | 2026-07-09:OfficeCLI 以 92% 日增幅入围
学习·开源·github
大E帝国子民16 小时前
Docker 部署 RocketMQ 5
docker·容器·rocketmq
柒星栈6 小时前
国产大模型“三国杀“:豆包收费、DeepSeek 开源、Kimi 2.5 万亿参数
人工智能·开源
文慧的科技江湖7 小时前
一文读懂光伏、储能,充电工作原理,是如何实现闭环的,其中微电网(ems)是什么;这个内容,就看懂了源网荷储。十五五规划里面最核心的能源管理内容
开源·springboot·储能·光伏