赞
踩
一般都是下载github上的composer包,但在国内容易被墙,可以在DaoCloud下载
github
curl -L https://github.com/docker/compose/releases/download/1.24.1/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
DaoCloud
curl -L https://get.daocloud.io/docker/compose/releases/download/1.24.1/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
将配置信息添加到Composer的全局配置文件 config.json
中
composer config -g repo.packagist composer https://packagist.phpcomposer.com
修改当前项目的 composer.json
配置文件,进入项目根目录,执行
composer config repo.packagist composer https://packagist.phpcomposer.com
自行添加也可,在项目中的 composer.json
文件的末尾添加
"repositories": {
"packagist": {
"type": "composer",
"url": "https://packagist.phpcomposer.com"
}
}
恢复到 packagist 官方源
composer config -g --unset repos.packagist
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。