Skip to content

Instantly share code, notes, and snippets.

View Aisuko's full-sized avatar
:octocat:
Etupirka

Aisuko Aisuko

:octocat:
Etupirka
View GitHub Profile
@Aisuko
Aisuko / cluster.yml
Last active August 20, 2019 11:17
The config of RKE to create Kubernetes master HA and Rancher HA. You need to deploy NGINX keep-alive and CoreDNS for you Kubernetes. https://rancher.com/docs/rancher/v2.x/en/installation/ha/
nodes:
- address: <IP_NODE_1>
user: rancher
role:
- controlplane
- etcd
- worker
hostname_override: master1
# internal_address: 172.16.22.11
# ssh_key_path: /home/user/.ssh/id_rsa
@Aisuko
Aisuko / nginx.conf
Last active July 29, 2019 02:41
The nginx config for Rancher HA LoadBalance.
worker_processes 4;
worker_rlimit_nofile 40000;
events {
worker_connections 8192;
}
stream {
upstream rancher_servers_http {
least_conn;
@Aisuko
Aisuko / change_passed.sh
Last active August 6, 2019 06:50
change_passed.sh
ansible -i templ.host all -m shell -a "echo <yourpasswd>|passwd rancher --stdin"
@Aisuko
Aisuko / kubebuilder.sh
Created August 15, 2019 06:11
Download kubebuilder beta version.
curl -sL https://go.kubebuilder.io/dl/2.0.0-beta.0/darwin/amd64 | tar -xz -C /tmp/
@Aisuko
Aisuko / nginx.conf
Created August 16, 2019 09:37
The nginx.conf of rancher nginx load balance by private certificate.
worker_processes 4;
worker_rlimit_nofile 40000;
events {
worker_connections 8192;
}
http {
upstream rancher {
server <worker_node_ip>:443;
ansible -i templ.host all -m copy -a "src=./daemon.json dest=/etc/docker/daemon.json"
@Aisuko
Aisuko / busybox.yaml
Last active August 28, 2019 07:51
Debug kubernetes DNS contaianer.`kubectl exec -it busybox nslookup kubernetes`
apiVersion: v1
kind: Pod
metadata:
name: busybox
namespace: default
spec:
containers:
- image: busybox:1.28
command:
- sleep
@Aisuko
Aisuko / setup_disk.sh
Created August 28, 2019 13:57
The process of mounting the disk to linux distributed without shutdown.
fdisk -l
fdisk /dev/sdb
# new
n
t
# linux system file
8e
@Aisuko
Aisuko / shadosocks-manager
Created September 14, 2019 04:36
shadowsocks manager scripts
启动:/etc/init.d/shadowsocks-manager start
停止:/etc/init.d/shadowsocks-manager stop
重启:/etc/init.d/shadowsocks-manager restart
查看状态:/etc/init.d/shadowsocks-manager status
git rm -r --cached mesheryIstio