Created
February 3, 2015 11:51
-
-
Save gong023/fa1dc46e4fccacddd78d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
PHP_VER='5.6.3' | |
sudo rpm -ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm | |
sudo rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm | |
sudo yum install -y mysql mysql-devel mysql-server mysql-utilities --enablerepo=remi | |
sudo /etc/init.d/mysqld start | |
mysql -uroot -e 'create database ma_report_test' | |
sudo yum install -y git | |
(curl https://raw.githubusercontent.com/CHH/phpenv/master/bin/phpenv-install.sh | bash) | |
git clone git://github.com/CHH/php-build.git ~/.phpenv/plugins/php-build | |
echo 'export PATH="$HOME/.phpenv/bin:$PATH"' >> ~/.bashrc | |
echo 'eval "$(phpenv init -)"' >> ~/.bashrc | |
exec $SHELL -l | |
sudo yum install -y libxml2-devel curl-devel libjpeg-devel libpng-devel libmcrypt-devel libtidy-devel libxslt-devel | |
phpenv install ${PHP_VER} | |
echo ${PHP_VER} > ~/.phpenv/version | |
(curl -sS https://getcomposer.org/installer | php) | |
sudo mv composer.phar /usr/local/bin/composer | |
cd /vagrant | |
composer install | |
# xdebug用 | |
sudo /etc/init.d/iptables stop | |
sudo chkconfig iptables off | |
echo ' | |
xdebug.remote_enable=On | |
xdebug.remote_connect_back=On | |
xdebug.remote_autostart=On | |
xdebug.remote_host=10.99.0.4 | |
xdebug.remote_port=9000 | |
xdebug.max_nesting_level=1000 | |
xdebug.idekey="intellijidekey"' >> /home/vagrant/.phpenv/versions/5.6.3/etc/conf.d/xdebug.ini | |
echo 'export XDEBUG_CONFIG="idekey=intellijidekey"' >> ~/.bashrc | |
exec $SHELL -l |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment