摘要:macbook安装php环境的方法:首先安装brew;然后通过命令“brew install php@7.1”安装php7.1;接着安装mysql5.7以及nginx;最后通过start命令启动PHP即可。推荐:《PHP视频教程》mac
macbook安装php环境的方法:首先安装brew;然后通过命令“brew install php@7.1”安装php7.1;接着安装mysql5.7以及nginx;最后通过start命令启动PHP即可。
推荐:《PHP视频教程》
mac安装php环境
安装brew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
安装php7.1
brew install php@7.1
安装mysql5.7
brew install mysql@5.7
安装nginx
brew install nginx
启动nginx
brew services start nginx
启动PHP
brew services start php@7.1
启动mysql
brew services start mysql@5.7 /usr/local/opt/mysql@5.7/bin/mysql.server start
php一些路径
/usr/local/opt/php@7.1/bin/php /usr/local/Cellar/php@7.1/7.1.28/bin/phpize
php-fpm配置文件 (php运行用户在这里改user和group)
/usr/local/Cellar/php@7.1/7.1.28/.bottle/etc/php/7.1/php-fpm.d/www.conf php.ini /usr/local/etc/php/7.1/php.ini nginx.conf /usr/local/etc/nginx/nginx.conf my.cnf /usr/local/etc/my.cnf
相关文章推荐
网站谷歌评分90+意味着什么?2022-09-06
怎样将不安全网站变成安全网站访问?2022-09-26
网站排名下降,可能跟算法更新没关系2022-09-20
网站如何设置高质量的网页标题?2022-09-14
做外贸网站选哪些语言?法语、德语最吃香2022-09-13