准备:
text 代码:一台带宝塔面板的服务器
Chevereto 压缩包
第一步
前往这里下载 Chevereto 压缩包,一会就可以下载完成
中文配置参考这里:How to Install - 如何安装
第二步
进入宝塔面板,在网站菜单,点击添加站点,如下图
填入域名(可以携带端口),数据库选择MYSQL,数据库用户名密码根据自己需要设置,再点击提交即可
第三步
进入网站的根目录,把下载的 Chevereto 压缩包上传并解压
第四步
这个时候需要对设置进行调整,在网站处,点击设置
找到配置文件
在最后一个大括号前加入下面的代码
加完之后是这样的
需要增加的代码如下:
Disable access to .ht* files
location ~ /\.ht {
deny all;
}
location ~ /(appcontentlib)/.*\.(pophplocksql)$ {
deny all;
}
Disable log on not found images + image replacement
location ~* (jpe?gpnggif) {
log_not_found off;
error_page 404 /contenthttps://qn.cndrew.cn/system/default/404.gif;
}
Enable CORS header (needed for CDN)
location ~* \.(ttfttcotfeotwoffwoff2cssjs)$ {
add_header Access-Control-Allow-Origin "*";
}
Force serve upload path as static content (match your upload folder if needed)
location https://qn.cndrew.cn {}
Route dynamic request to index.php
location / {
try_files $uri $uri/ /index.php?$query_string;
}
第五步
然后通过前面填写域名进入到你新建的网站,跟随着设置一步一步来就行。这里会让你输入一次你的数据库的名字账号和密码,把你上面新建的那个输进去就好了
全部设置好之后你会获得一个管理员账号(名字密码都是自己设置的。点击登陆进去可以进入仪表盘设置网站的外观和配置。可以切换语言。
然后到这里就搭建结束了。