使用FTP,找到 /etc/nginx/ 目录下的nginx.conf文件,在http部分增加开启gizp的命令,然后重启Nginx服务器,具体见下图。
目录:服务器
Nginx服务器伪静态配置文件 nginx.conf和rewrite.conf 详解
Nginx里使用伪静态是直接在nginx.conf中写规则的,nginx.conf 文件在服务器的地址,我用的腾讯的云主机,系统是CentOS,登录后直接使用find -name ‘nginx.cong’ 命令查找nginx.conf文件即可,我的nginx.conf 在 /etc/nginx/nginx.conf,具体见下图:
腾讯云服务器 FTP 端口设置为22 连接方式SSH/SFTP
腾讯云服务器, 操作系统为CentOS 7.4 64位,FTP 端口设置为22 连接方式SSH/SFTP,否则FTP连接不了服务器。 阅读全文
Cent OS7 apache nginx mysql php-fpm 启动 停止 重启 命令
Centos7重启apache、nginx、mysql、php-fpm命令
apache
启动
systemctl start httpd
停止
systemctl stop httpd
重启
systemctl restart httpd
mysql
启动
systemctl start mysqld
停止
systemctl stop mysqld
重启
systemctl restart mysqld
php-fpm
启动
systemctl start php-fpm
停止
systemctl stop php-fpm
重启
systemctl restart php-fpm
nginx
启动
systemctl start nginx
停止
systemctl stop nginx
重启
systemctl restart nginx
美国虚拟主机Bluehost推荐
美国Bluehost虚拟主机不限流量,不限空间,支持PHP&MySQL,一个帐户下可建立无数个网站,赠送一个免费域名,价格只有4.95美元/月,如果有需要可购买一个独立IP。Bluehost官方网址:http://www.bluehost.com 阅读全文