在linux和macOS下此命令有效:
ssh -D 1337 -q -C -N your_server- 假设本地用户ssh key已经设置到your_server
- 本地1337端口即socks5代理的端口
| [node_pref] | |
| udp_flag=true | |
| tcp_fast_open_flag=true | |
| sort_flag=false | |
| skip_cert_verify_flag=true | |
| filter_deprecated_nodes=false | |
| ; --- 节点清洗与重命名 (强迫症福音) --- | |
| add_emoji=true | |
| remove_old_emoji=true | |
| exclude_remarks=(官网|到期|剩余|重置|更新|流量|VIP|群) |
| cls | |
| taskkill /F /FI "USERNAME eq %username%" /IM rdpclip.exe | |
| ping -n 1 -w 1000 1.1.1.1>nul | |
| start rdpclip.exe |
| #!/bin/bash | |
| # Note: | |
| # When the script prompts you to provide the dedicated configuration link, please copy and use the RAW link of your own Gist! | |
| # | |
| # 注意: | |
| # 当脚本提示你提供专属配置链接时,请使用你自己的Gist的RAW链接! | |
| # Required. |
| #!/bin/bash | |
| # Scale DOWN all Turbonetes PODs to 0 | |
| function turbo_stop_all_pods { | |
| turbo_stop_all_pods=$(kubectl get deploy -n turbonomic --no-headers=true | cut -d ' ' -f1 | xargs -I % kubectl scale --replicas=0 deployment/% -n turbonomic) | |
| while true; do | |
| if `kubectl get pods -n turbonomic | grep -v STATUS | wc -l` -gt 0 then | |
| echo -e "turbo_STOP_all_pods: Waiting on Turbonetes POD(s) to TERMINATE, so far: \n`kubectl get pods -n turbonomic | grep -v NAME`" | |
| elif | |
| [[ "$counter" -gt 30 ]]; then; | |
| echo "MAX Counter Reached! One or more PODs are stuck ##TERMINATING##, intervening to kill it/them" |
| #!/bin/sh | |
| # Launch a Pod ab-using a hostPath mount to land on a Kubernetes node cluster as root | |
| # without requiring `privileged: true`, in particular can abuse `DenyExecOnPrivileged` | |
| # admission controller. | |
| # Pod command in turn runs a privileged container using node's /var/run/docker.sock. | |
| # | |
| # Tweaked for PKS nodes, which run their docker stuff from different | |
| # /var/vcap/... paths | |
| node=${1} | |
| case "${node}" in |
| [Unit] | |
| Description=Keeps a tunnel to 'remote.example.com' open | |
| After=network.target | |
| [Service] | |
| User=autossh | |
| # -p [PORT] | |
| # -l [user] | |
| # -M 0 --> no monitoring | |
| # -N Just open the connection and do nothing (not interactive) |
##ss-redir 的 iptables 配置(透明代理)
透明代理指对客户端透明,客户端不需要进行任何设置就使用了网管设置的代理规则
创建 /etc/ss-redir.json 本地监听 7777
运行ss-redir -v -c /etc/ss-redir.json
iptables -t nat -N SHADOWSOCKS
# 在 nat 表中创建新链
iptables -t nat -A SHADOWSOCKS -p tcp --dport 23596 -j RETURN
# 23596 是 ss 代理服务器的端口,即远程 shadowsocks 服务器提供服务的端口,如果你有多个 ip 可用,但端口一致,就设置这个
| #!/bin/bash | |
| # create custom bootable iso for CentOS 7 with kickstart | |
| if [ $# -lt 2 ] | |
| then | |
| echo "Usage1: $0 path2iso path2kickstart" | |
| exit 1 | |
| else | |
| if [ ! -f $1 ] | |
| then |