Skip to content

jingjingxyk/build-kubernetes-website-with-docker

Repository files navigation

kubernetes calico istio janus ceph document website docker image

  1. kubernetes website mirror
  2. calico website mirror
  3. coturn website mirror
  4. developer.chrome.com website mirror
  5. ceph website mirror

coturn freeswitch janus nginx-quic image

  1. coturn
  2. freeswitch
  3. janus
  4. nginx-quic image

docker use proxy download image ; 使用代理下载容器镜像

  1. docker.io (docker hub公共镜像库)
  2. gcr.io (Google container registry)
  3. k8s.gcr.io (等同于gcr.io/google-containers)
  4. https://console.cloud.google.com/gcr/images/google-containers/GLOBAL
  5. quay.io (Red Hat运营的镜像库)
  6. ghcr.io (github 运营的镜像库)

docker proxy configure ; docker 代理 配置

proxy_url=http://your-porxy-server-ip:8118

line_number=$(grep -n '\[Service\]' /lib/systemd/system/docker.service | cut -d ':' -f 1 ) && echo $line_number
sed -i "${line_number}a\Environment=https_proxy=${proxy_url}" /lib/systemd/system/docker.service
sed -i "${line_number}a\Environment=http_proxy=${proxy_url}" /lib/systemd/system/docker.service
sed -i "${line_number}a\Environment=\"NO_PROXY=localhost,127.0.0.0/8,192.168.0.0/16,10.0.0.0/8,172.16.0.0/12,.aliyuncs.com\"" /lib/systemd/system/docker.service

systemctl daemon-reload
systemctl restart docker
cat /lib/systemd/system/docker.service
docker info

proxy tool 代理工具

cat <<EOF | tee proxy.sh
# your proxy server ip
ip=proxy.example.com

# your proxy server ssh key
keyfile=/key.pem

{
    ssh -o StrictHostKeyChecking=no \
    -o ExitOnForwardFailure=yes \
    -o TCPKeepAlive=yes \
    -o ServerAliveInterval=15 \
    -o ServerAliveCountMax=3 \
    -i $keyfile \
    -v -CTg \
    -D  0.0.0.0:8118 \
    root@$ip
} || {
    echo $?
}
EOF

# note you can use [autossh ] keep ssh live ;你能使用 autossh 保持ssh连接一直存活
apt install -y autossh

test

# 1. 只显示目录

ls -F | grep "/$"
ls -al | grep "^d"
# 2. 只显示文件
ls -al | grep "^-"


 ls -al | grep "^-" | awk '{print $9}' >  soft-list.txt

 # ls | while read line; do  echo $line ;done
#  i=0 ; while true ;  do  sleep 10 && clear && echo $((i++))  ; done


#find ./ -nouser  |xargs rm –rf