一、下载composer
wget https://dl.laravel-china.org/composer.phar -O /usr/local/bin/composer
二、打开权限
chmod a+x /usr/local/bin/composer
三、安装Laravel
composer global require "laravel/installer"
四、添加到环境变量中
export PATH=$PATH:/root/.config/composer/vendor/bin
source /etc/profile
五、创建Laravel项目
laravel new xxx