自用國內經常使用鏡像(20190918更新)

國內開源鏡像:

騰訊開源鏡像 https://opsx.alibaba.com/mirror
阿里開源鏡像 https://mirrors.cloud.tencent.com/

nuget(cnblogs國內鏡像):

https://nuget.cnblogs.com/v3/index.json

php(composer國內鏡像):

國內composer下載地址: https://mirrors.aliyun.com/composer/composer.pharphp

https://packagist.phpcomposer.com
https://mirrors.aliyun.com/composer/

打開命令行窗口(windows用戶)或控制檯(Linux、Mac 用戶),進入你的項目的根目錄(也就是 composer.json 文件所在目錄),執行以下命令:node

composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

nodejs(npm國內鏡像):

https://npm.taobao.org/
npm set registry=https://registry.npm.taobao.org # 註冊模塊鏡像

npm set disturl=https://npm.taobao.org/dist # node-gyp 編譯依賴的 node 源碼鏡像

npm set chromedriver_cdnurl=https://npm.taobao.org/mirrors/chromedriver # chromedriver 二進制包鏡像
npm set operadriver_cdnurl=https://npm.taobao.org/mirrors/operadriver # operadriver 二進制包鏡像
npm set phantomjs_cdnurl=https://npm.taobao.org/mirrors/phantomjs # phantomjs 二進制包鏡像
npm set sass_binary_site=https://npm.taobao.org/mirrors/node-sass/ # node-sass 二進制包鏡像
npm set electron_mirror=https://npm.taobao.org/mirrors/electron/ # electron 二進制包鏡像

npm set selenium_cdnurl=http://npm.taobao.org/mirrors/selenium
npm set node_inspector_cdnurl=https://npm.taobao.org/mirrors/node-inspector

ruby(gem國內鏡像):

https://gems.ruby-china.org/
https://ruby.taobao.org/

gem sources --add https://gems.ruby-china.org/ --remove https://rubygems.org/
bundle config mirror.https://rubygems.org https://gems.ruby-china.org

golang(第三方包下載地址):

https://gopm.io/

阿里雲的maven鏡像:

maven { url 'http://maven.aliyun.com/mvn/repository/' }

linux(國內鏡像):

http://mirrors.aliyun.com/
https://mirrors.cloud.tencent.com/

deb http://mirrors.aliyun.com/dotdeb jessie all
deb-src http://mirrors.aliyun.com/dotdeb jessie all

ubuntu:

git: sudo add-apt-repository ppa:git-core/ppa
php7: sudo add-apt-repository ppa:ondrej/php
wine: sudo add-apt-repository ppa:ubuntu-wine/ppa
python: sudo add-apt-repository ppa:fkrull/deadsnakes
ansible: sudo add-apt-repository ppa:ansible/ansible

postgresql:
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main

 

mariadb(用的韓國鏡像):

sudo apt-get install python-software-properties

sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xcbcb082a1bb943db 
sudo add-apt-repository 'deb [arch=amd64,i386] http://ftp.kaist.ac.kr/mariadb/repo/10.1/debian wheezy main'

nginx:

wget -O - http://nginx.org/keys/nginx_signing.key | sudo apt-key add -
echo 'deb http://nginx.org/packages/ubuntu/ trusty nginx' | sudo tee /etc/apt/sources.list.d/nginx.list
echo 'deb-src http://nginx.org/packages/ubuntu/ trusty nginx' | sudo tee -a /etc/apt/sources.list.d/nginx.list

chrome(國內下載地址):

https://api.shuax.com/tools/getchrome

git-for-windows(國內鏡像):

https://npm.taobao.org/mirrors/git-for-windows/

python(國內鏡像):

https://pypi.tuna.tsinghua.edu.cn/simple

例子: pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pyspider

全局修改 ~/.pip/pip.conf (沒有就建立一個文件夾及文件。文件夾要加「.」,表示是隱藏文件夾)

內容以下:

[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host=mirrors.aliyun.com
相關文章
相關標籤/搜索