完成 72绵阳项目 71雄安集团监管平台 大量优化更新
This commit is contained in:
24
998-常用脚本/a-部署脚本/APT代理方式.sh
Normal file
24
998-常用脚本/a-部署脚本/APT代理方式.sh
Normal file
@@ -0,0 +1,24 @@
|
||||
|
||||
|
||||
# master节点
|
||||
sudo apt update
|
||||
sudo apt install -y apt-cacher-ng
|
||||
|
||||
|
||||
systemctl status apt-cacher-ng
|
||||
|
||||
|
||||
|
||||
# worker节点
|
||||
|
||||
sudo tee /etc/apt/apt.conf.d/01proxy <<EOF
|
||||
Acquire::http::Proxy "http://10.22.57.8:3142";
|
||||
Acquire::https::Proxy "http://10.22.57.8:3142";
|
||||
EOF
|
||||
|
||||
|
||||
ssh root@${server} "printf '%s\n' \
|
||||
'Acquire::http::Proxy \"http://10.22.57.8:3142\";' \
|
||||
'Acquire::https::Proxy \"http://10.22.57.8:3142\";' \
|
||||
| tee /etc/apt/apt.conf.d/01proxy >/dev/null"
|
||||
|
||||
Reference in New Issue
Block a user