如何使用 chevereto 搭建免費圖床系統(tǒng)

在 VPS 上搭建自己的圖床,這次我們使用 chevereto 這個程序。你需要在服務(wù)器上有 Nginx、PHP、MySQL,我們使用一鍵安裝包進行安裝。

安裝 LNMP

yum -y install wget screen curl python git
wget http://mirrors.linuxeye.com/lnmp-full.tar.gz
tar xzf lnmp-full.tar.gz
cd lnmp
screen -S lnmp
./install.sh

這個過程比較漫長,可參考視頻中的選項進行配置,安裝成功后記錄你的配置文件,如:

Nginx install dir:              /usr/local/nginx

Database install dir:           /usr/local/mysql
Database data dir:              /data/mysql
Database user:                  root
Database password:              ******你的數(shù)據(jù)庫密碼

PHP install dir:                /usr/local/php

phpMyAdmin dir:                 /data/wwwroot/default/phpMyAdmin
phpMyAdmin Control Panel URL:
http://你的 IP 地址/phpMyAdmin

Index URL:                      http://你的 IP 地址/

配置虛擬主機

cd lnmp
./vhost.sh

根據(jù)視頻中操作添加虛擬主機,如果沒有域名的話就不用添加了!!

配置好虛擬主機后記錄下你的站點配置,如:

Your domain:                  images.ruoxiaozh.com
Virtualhost conf:             /usr/local/nginx/conf/vhost/images.ruoxiaozh.com.conf
Directory of:                 /data/wwwroot/images.ruoxiaozh.com
Let's Encrypt SSL Certificate:/usr/local/nginx/conf/ssl/images.ruoxiaozh.com.crt
SSL Private Key:              /usr/local/nginx/conf/ssl/images.ruoxiaozh.comg.key

安裝 Chevereto

下載源碼(記得安裝 git 哦)

git clone https://github.com/Chevereto/Chevereto-Free && mv Chevereto-Free/* ./ && rm -rf Chevereto-Free

www 用戶授權(quán)

chown -R www:www /data/wwwroot/images.ruoxiaozh.com

修改 nginx 配置(/usr/local/nginx/conf/vhost/你的站點.conf),添加如下配置:

location / {
    try_files $uri $uri/ /index.php?$query_string;
}

讓配置文件生效

service nginx reload

創(chuàng)建數(shù)據(jù)庫 chevereto

然后按照操作步驟就開始安裝了...

就是這樣的, 這里是訪問地址 https://images.ruoxiaozh.com

image
最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容