"lamp"


~ yum -y install httpd mysql mysql-server php php-mysql php-gd php-mbstring
启动服务

~ service httpd start
~ service mysqld start


开启PHP错误提示:1)vi /etc/php.ini 2)设置display_errors = On(530行左右)
关闭防火墙 service iptables stop
关闭selinux vi /etc/selinux/config
PHP代码默认放在/var/www/html
设置自启动

~ chkconfig httpd --level 2345 on
~ chkconfig mysqld --level 2345 on



"lnmp"


~ yum -y install nginx mysql mysql-server php php-mysql php-gd php-mbstring php-fpm


启动服务

~ service nginx start
~ service mysqld start
~ service php-fpm start


设置自启动

~ chkconfig nginx --level 2345 on
~ chkconfig mysqld --level 2345 on
~ chkconfig php-fpm --level 2345 on


如何用dockerfile 和 docker compose 安装php82

1.创建Dockerfile 文件名:Dockerfile.php-fpm82 FROM php:8.2-fpm # 安装必要的依赖 RUN apt-get update && apt-get install -y --no-install-recom...

阅读全文

Linux使用lsyncd实现2个文件夹实时同步

官方文档: https://axkibe.github.io/lsyncd/download/ 1.安装 $ yum install lsyncd $ yum install rsync $ yum install libtermcap-devel ncurses-devel l...

阅读全文

firewall 防火墙常用命令

查看版本 $ firewall-cmd --version 0.4.3.3 help $ firewall-cmd --help 状态 $ firewall-cmd --state running 重载配置 $ firewall-cmd --reload 重新加载...

阅读全文

欢迎留言