LNMP架构环境之PHP+Mariadb环境项目:部署博客wordpress项目

时间:2023-01-05 11:04:08

1)配置nginx 博客虚拟主机

cat >/etc/nginx/conf.d/02_blog.etiantian.org.conf<

server {

server_name blog.etiantian.org;

listen 80;

root /data/blog;

index index.php index.html;

location ~ \.php\$ {

#root /data/blog;

fastcgi_pass 127.0.0.1:9000;

fastcgi_index index.php;

fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name;

include fastcgi_params;

}

}

EOF

cat /etc/nginx/conf.d/02_blog.etiantian.org.conf

nginx -t

systemctl restart nginx

2)配置博客站点目录

mkdir -p /data/blog

cd /data/blog

下载blog程序

wget ​https://cn.wordpress.org/latest-zh_CN.zip

unzip latest-zh_CN.zip

mv wordpress/* .

chown -R www.www /data/blog/

3)做Hosts解析:

10.0.0.41 pan.etiantian.org blog.etiantian.org

4)浏览器blog.etiantian.org安装见结尾云盘视频

5)最终效果

LNMP架构环境之PHP+Mariadb环境项目:部署博客wordpress项目

LNMP架构环境之PHP+Mariadb环境项目:部署博客wordpress项目

点击运行安装程序