基于lnmp搭建workpress

部署Nginx

第一步:下载、上传到服务器后

yum install pcre-devel automake make zlib zlib-devel gcc-c++ libtool openssl openssl-devel -y

tar -zxvf nginx-1.20.2.tar.gz -C /usr/local/src

useradd nginx -s /sbin/nologin -M

[root@localhost nginx-1.14.2]# .configure \
> > --user=nginx \
> --group=nginx \
> --prefix=/usr/local/nginx \
> --with-http_ssl_module \
> --with-http_sub_module  \
> --with-http_stub_status_module \
> --with-http_gzip_static_module \
> --with-pcre
[root@localhost nginx-1.14.2]# make && make install
[root@localhost nginx-1.14.2]# cd /usr/local/src/nginx-1.14.2/sbin/nginx -t

[root@localhost nginx-1.14.2]# cd /usr/local/src/nginx-1.14.2/sbin/nginx

在浏览器中测试192.168.201.144

安装MySQL

先将压缩包上传到local目录下,将压缩 包解压

安装PHP

tar -zxvf php-8.1.4.tar.gz -C /usr/local/


yum install zlib libxml libjpeg freetype libpng gd curl libiconv zlib-devel libxml2 libxml2-devel libjpeg-devel freetype-devel libpng-devel gd-devel curl-devel openssl-devel libxslt-devel -y


./configure --prefix=/usr/local/php8 --with-apxs2=/usr/bin/apxs --with-mysql=/usr/share/mysql --with-xmlrpc --with-openssl  --with-zlib --with-freetype-dir --with-gd --with-jpeg-dir --with-png-dir --with-iconv --enable-short-tags --enable-sockets --enable-zend-multibyte --enable-soap --enable-mbstring --enable-static --enable-gd-native-ttf --with-curl --with-xsl --enable-ftp --with-libxml-dir

make && make install

编译成功会显示下图

 在浏览器用192.168.201.144 访问

[root@bogon local]# yum install unzip -y

[root@bogon local]# unzip wordpress-4.9.4-zh_CN.zip

[root@bogon local]# mv wordpress /var/www/html/

[root@bogon local]# chown -R nginx:nginx /var/www/html

接下来按部就班就可以,一直到出现下图安装成功 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值