中國 DNS 列表
阿里雲
- 223.5.5.5
- 223.6.6.6
114DNS
- 114.114.114.114
- 114.114.115.115
中國 DNS 列表
阿里雲
114DNS
| tar xvJf ***.tar.xz |
| ruby -ryaml -rjson -e 'puts JSON.pretty_generate(YAML.load(ARGF))' < file.yml > file.json |
| curl -O http://7xj5oe.com1.z0.glb.clouddn.com/files/chef-12.3.0-1.dmg | |
| open chef-12.3.0-1.dmg |
| cat ~/.ssh/id_rsa.pub | ssh user@machine "mkdir ~/.ssh; cat >> ~/.ssh/authorized_keys" |
| # curl -sL https://git.io/v1sVj | sudo bash | |
| #!/usr/bin/env bash | |
| RUBY_VERSION='2.2.1' | |
| CHEF_VERSION='12.3.0' | |
| echo 'ubuntu ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers | |
| sudo locale-gen --lang zh_TW.UTF-8 |
| sudo apt-get -y update | |
| sudo apt-get --no-install-recommends -y install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev libgdbm-dev ncurses-dev automake libtool bison subversion pkg-config libffi-dev vim | |
| # Download and compile Ruby 2.0.0-p0 | |
| cd /tmp | |
| #wget ftp://ftp.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p0.tar.gz | |
| wget http://ruby.taobao.org/mirrors/ruby/2.0/ruby-2.0.0-p353.tar.gz | |
| tar -xvzf ruby-2.0.0-*.tar.gz | |
| cd ruby-2.0.0-* | |
| ./configure --prefix=/usr/local |
| # bash < <( curl -L https://gist.githubusercontent.com/SammyLin/974def3b8f4cd84ce284/raw/31cbdaacb5d85f5ad483e58673f70f3a60699210/gistfile1.sh ) | |
| #!/bin/bash | |
| set -e | |
| echo 'hi' |
| #!/bin/bash | |
| find . -name _vti_cnf -exec rm -rf {} \; | |
| find . -name _borders -exec rm -rf {} \; | |
| find . -name _private -exec rm -rf {} \; | |
| find . -name _vti_pvt -exec rm -rf {} \; | |
| find . -name _vti_txt -exec rm -rf {} \; | |
| find . -name _vti_script -exec rm -rf {} \; | |
| find . -name .DS_Store -exec rm -rf {} \; | |
| find . -name WS_FTP.LOG -exec rm -rf {} \; |
| check process solr-<%= fetch(:application) %> with pidfile <%= "#{shared_path}/pids/sunspot-solr.pid" %> | |
| start program = "/bin/su - deploy -c 'cd <%= current_path %> && <%= SSHKit.config.command_map[:bundle] %> exec sunspot-solr start --port=8983 --data-directory=<%= shared_path %>/solr/data --pid-dir=<%= shared_path %>/pids'" | |
| stop program = "/bin/su - deploy -c 'cd <%= current_path %> && <%= SSHKit.config.command_map[:bundle] %> exec sunspot-solr stop --pid-dir=<%= shared_path %>/pids'" | |
| if failed host 127.0.0.1 port 8983 protocol http and request "/solr" then restart | |
| if 3 restarts within 5 cycles then timeout |