ubuntu 16.04 php 开发环境搭建
2016-05-01 14:25
656 查看
ubuntu 16.04 php 开发环境搭建
mysql
sudo apt install -y mysql-server mysql-client
php 5.6
sudo add-apt-repository -y ppa:ondrej/php sudo apt update sudo apt install -y php5.6 php5.6-fpm php5.6-mysql php5.6-mbstring php5.6-curl php5.6-xml
nginx
sudo apt install -y nginx
sudo vim /etc/nginx/sites-enabled/default
# root /var/www/html; root /project/path; ... location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php5.6-fpm.sock; }
sudo systemctl reload nginx
phpstorm
sudo apt install -y php-xdebug sudo vim /etc/php/5.6/mods-available/xdebug.ini
xdebug.remote_enable=1 xdebug.remote_host=localhost xdebug.remote_port=9000 xdebug.idekey=PHPSTROM
sudo systemctl restart php5.6-fpm
Go to http://www.jetbrains.com/phpstorm/marklets/
Click the Generate button under the Xdebug section, then drag the links “Start debugger” and “Stop debugger” from the Debug section that appears to the Bookmarks Toolbar.
参考资料:
https://askubuntu.com/questions/756181/installing-php-5-6-on-xenial-16-04
https://confluence.jetbrains.com/display/PhpStorm/Zero-configuration+Web+Application+Debugging+with+Xdebug+and+PhpStorm
相关文章推荐
- 一个关于if else容易迷惑的问题
- Ubuntu 默认壁纸历代记
- Ubuntu Remix Cinnamon 20.04 评测:Ubuntu 与 Cinnamon 的完美融合
- 关于Ubuntu 11.10启动提示waiting for the network configuration的问题
- 在 Ubuntu 桌面中使用文件和文件夹
- PHP5.2.*防止Hash冲突拒绝服务攻击的Patch
- 深入理解PHP之匿名函数
- ubuntu下chrome无法同步问题解决
- Ubuntu Linux使用体验
- JSP/PHP基于Ajax的分页功能实现
- 使用 GNOME 优化工具自定义 Linux 桌面的 10 种方法
- 以Ubuntu 9.04为例 将工作环境迁移到 Linux
- 关于PHP通过PDO用中文条件查询MySQL的问题。
- 什么是设计模式
- VirtualBox虚拟机XP与宿主机Ubuntu互访共享文件夹
- 从USB安装Ubuntu Server 10.04.3 图文详解
- Ubuntu 15.04 正式版发布下载
- Linux-Ubuntu 10.04安装Cadence-ic610 方法总结图解
- Ubuntu 12.04和Windows 7双系统安装图解