banner
 Sayyiku

Sayyiku

Chaos is a ladder
telegram
twitter

Chevereto v4 专业版搭建个人图床教程以及问题排查

开心版想体验的下载:地址#

1. 宝塔面板安装#

环境需求#

PHP 版本要求 8.0 及以上,MySQL 版本支持 5.x 及 8.0, fileinfo、imagemagick 和 exif 三个 php 扩展

image

上传获得授权的安装包并解压缩#

image

配置 nginx 伪静态#

location ~* /(importing|app|content|lib)/.*\.(po|php|lock|sql)$ {
    deny all;
}
location ~ \.(jpe?g|png|gif|webp)$ {
    log_not_found off;
    error_page 404 /content/images/system/default/404.gif;
}
location ~* /.*\.(ttf|ttc|otf|eot|woff|woff2|font.css|css|js)$ {
    add_header Access-Control-Allow-Origin "*";
}
location / {
    index index.php;
    try_files $uri $uri/ /index.php$is_args$query_string;
}

image

开始安装#

访问域名或者 ip 进行安装

image

可能遇到的问题#

image

解决办法#

关闭宝塔网站目录里的防跨站攻击

image

2.docker 安装(推荐)#

#优点#

  • 🤹 多个网站实例

  • 📱 便携带性

  • 🌈易于维护

  • 🔐 自动 HTTPS 设置

  • 🎨 定制

  • 👮‍♂️更安全

  • 🌎 CloudFlare 集成

要求#

Docker 一键安装#

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh

克隆 chevereto/docker#

git clone https://github.com/chevereto/docker.git
cd docker

设置 Cron#

此过程创建一个 Cron 文件,/etc/cron.d/chevereto该文件将为服务器中的所有 Chevereto 实例运行后台作业。

make cron

创建代理#

此过程创建代理服务来处理传入的网络流量到服务器。它还将为 HTTPS 提供自动安全证书。

EMAIL_HTTPS选项中传递您的电子邮件。

make proxy EMAIL_HTTPS=mail@yourdomain.tld

构建 Chevereto#

此过程为 Chevereto 应用程序构建容器。

make image

#设置命名空间#

为您要部署的每个 Chevereto 实例创建一个命名空间 (opens new window) 。

为 vps 创建**example**命名空间**img.chevereto.dev**(需要替换成你要部署的域名):

make namespace NAMESPACE=example HOSTNAME=img.chevereto.dev

启动 Chevereto#

make spawn通过传递 NAMESPACE 选择项来创建实例运行命令。

make spawn NAMESPACE=example

🎉恭喜,Chevereto 现在已经启动。

要创建更多实例,请为您要生成的每个其他网站重新设置命名空间中的步骤。

加载中...
此文章数据所有权由区块链加密技术和智能合约保障仅归创作者所有。