通过 Docker 快速部署 zlib-searcher 实例

通过 Docker 快速部署 zlib-searcher 实例

dejavuBlog
本文是给纯小白看滴(页面打开空白,翻页没有数据,搜索没反应……其实只有一个原因,你部署了 Docker 容器,但是没有下载 zlib-searcher 的索引数据

安装 Docker

如果你的机器上只有 root 用户去掉下面所有的 sudo 即可

以 Debian/GNU Linux 为例,其他系统查看 Docker 文档: CentOS|Fedora|Ubuntu|RHEL

sudo apt update && \
sudo apt install -y ca-certificates \
 curl \
 gnupg \
 lsb-release

然后

sudo mkdir -p /etc/apt/keyrings && \
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg && \
echo \
 "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \
 $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

安装 Docker 和 docker compose 插件

sudo apt update && \
sudo apt install -y docker-ce \
docker-ce-cli \
containerd.io \
docker-compose-plugin

开始部署

# 如果您的服务器没有 unzip 
sudo apt install -y unzip 
​
git clone https://github.com/zlib-searcher/zlib-searcher.git && \
cd zlib-searcher && \
wget https://github.com/zlib-searcher/zlib-searcher/releases/download/0.6.0/index_0.6.zip && \
unzip index_0.6.zip && \
sudo docker compose up -d

现在访问 7070 端口就可以访问了,如果你在家庭无公网的机器上搭建,可以 使用 Cloudflare Tunnel 监听本地 7070 端口绑定域名就可以在线访问啦~


Report Page