|
安装nginx yum -y install nginx systemctl start nginx 首页在 /usr/share/nginx/html 安装mysql数据库 yum -y install mariadb mariadb-server systemctl start mariadb systemctl enable mariadb mysql -uroot -p123 安装php yum -y install php php-fpm php-mysqlndphp-gd php-mbstring php-xml php-zip php-bcmath php-intl php-curl systemctl enable php-fpm nginx配置代理php
vim /etc/nginx/nginx.conf location ~ \.php$ { root /usr/share/nginx/html; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME$document_root$fastcgi_script_name; include fastcgi_params; } systemctl restart nginx 1. 创建php测试页 echo '<?php phpinfo(); ?>' >/usr/share/nginx/html/info.php 浏览器访问 47.76.86.226/info.php 6.安装discuz x3.5 unzip Discuz_X3.5_SC_UTF8_20260504.zip mv ./upload/ /usr/share/nginx/html/discuz/ cd /usr/share/nginx/html/discuz/ ls chown -R root:nginx ./config/ chown -R root:nginx ./data/ chown -R root:nginx ./uc_client/ chown -R root:nginx ./uc_server/ chmod -R 777 ./config/ chmod -R 777 ./data/ chmod -R 777 ./uc_client/ chmod -R 777 ./uc_server/ 7.数据库授权 Mysql -uroot -p123 create database bbs; grant all privileges on *.* to 'root'@'%'identified by '123'; grant all privileges on *.* to'root'@'localhost' identified by '123'; flush privileges; 浏览器访问 47.76.86.226/discuz (直接访问) 8.配置https 创建目录 mkdir -p /etc/nginx/ssl && cd/etc/nginx/ssl 证书: openssl req -x509 -nodes -days 365 -newkeyrsa:2048 -keyout nginx-selfsigned.key -out nginx-selfsigned.crt 到nginx文件修改 vim /etc/nginx/nginx.conf server { listen 443 ssl; listen [::]:80; root /usr/share/nginx/html; server_name 47.76.86.226; ssl_certificate /etc/nginx/ssl/nginx-selfsigned.crt; ssl_certificate_key /etc/nginx/ssl/nginx-selfsigned.key; ssl_protocols TLSv1.2 TLSv1.3; ssl_ciphers HIGH:!aNULL:!MD5; nginx -t systemctl restart nginx.service 重新访问 Cd /usr/share/nginx/html Rz sy.zip html的页面 Unzip sy.zip 覆盖原有的index.html 或者删除原有 后续更改只换有变动的就可以 例: Rm -rf index.html Rz
Dns域名设置
就可以正常解析了
论坛的ip隐藏 <a href="https://www.yxr888.xyz/discuz/"target="_blank"> 管理员用户登录 sumz 123 天龙八部 cd / Rz
tar vxzftlbb.tar.gz 权限 chmod -R 777/home/ chmod -R 777/opt/ 运行命令 cd opt sh tl.sh vim /home/tlbb/Server/Config/ServerInfo.ini (3处修改)
cd /home/tlbb sh run.sh cd /usr/share/nginx/html/ mkdir tlbb cd tlbb Rz 客户端.zip Vim /usr/share/nginx/html/index.html
<a href="tlbb/客户端.zip" download= "客户端.zip">
|