Skip to content

Instantly share code, notes, and snippets.

View gongzili456's full-sized avatar
🎉
Just For Fun

Rory gongzili456

🎉
Just For Fun
View GitHub Profile
# macOS Global Key Bindings
## Ctrl +
- F: Move forward letter
- B: Move backward letter
- P: Move previous line
- N: Move next line
- A: Move ahead of line
- E: Move end of line
- T: Transpose letter
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-nginx
namespace: default
labels:
app: my-nginx
spec:
selector:
matchLabels:
#!/bin/bash
# Ubuntu 18.04 系统环境
# 1. 安装并开启 BBR 拥塞控制算法
# 2. 安装 Docker CE
# 3. 安装 certbot
# 4. 安装 gost
# 5. 配置自动任务
update_core(){
#/bash/sh
sudo apt update
sudo apt install -y apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable"
sudo apt update
sudo apt -y install docker-ce
@gongzili456
gongzili456 / gist:0125a6d976f8336a949e8c00365db82e
Last active March 19, 2019 06:28
init-node-env-on-ubuntu.sh
#/bash/sh
# 1. install node.js
curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
sudo apt-get install -y nodejs
# 2. install nginx
sudo apt-get install nginx -y
# 3. install git
sudo xattr -rd com.apple.quarantine /Applications/[LockedApp].app
const COS = require('cos-nodejs-sdk-v5')
const params = {
AppId: '',
SecretId: '',
SecretKey: '',
}
const cos = new COS(params)
yum install http://opensource.wandisco.com/centos/6/git/x86_64/wandisco-git-release-6-1.noarch.rpm
yum install git
To get Docker running on the AWS AMI you should follow the steps below (these are all assuming you have ssh'd on to the EC2 instance).
Update the packages on your instance
[ec2-user ~]$ sudo yum update -y
Install Docker
[ec2-user ~]$ sudo yum install docker -y
Start the Docker Service
# 1. install shadowsocks
sudo pip install shadowsocks
sslocal -s 服务器域名或IP -p 服务器端口号 -k “密码” -l 1080 -t 600 -m rc4-md5
# append proxy=socks5://127.0.0.1:1080 to /etc/yum.conf
# update iptables to 1.4.21
wget http://ftp.netfilter.org/pub/iptables/iptables-1.4.21.tar.bz2
tar -xjf iptables-1.4.21.tar.bz2
cd iptables-1.4.21