文章摘要
旧絮 GPT
拼命加载中···

Ssh连接服务器

1
2
ssh -i 密钥路径 <用户名>@<ip>
sudo -i # 切换到root

哪吒面板

1
curl -L https://raw.githubusercontent.com/naiba/nezha/master/script/install.sh  -o nezha.sh && chmod +x nezha.sh && sudo ./nezha.sh

宝塔面板

1
if [ -f /usr/bin/curl ];then curl -sSO https://download.bt.cn/install/install_panel.sh;else wget -O install_panel.sh https://download.bt.cn/install/install_panel.sh;fi;bash install_panel.sh ed8484bec

1Panel

1
curl -sSL https://resource.1panel.pro/quick_start.sh -o quick_start.sh && bash quick_start.sh

Xrayr

1
2
3
4
5
6
7
8
#官方
bash <(curl -Ls https://raw.githubusercontent.com/XrayR-project/XrayR-release/master/install.sh)

#一键对接
wget -N https://raw.githubusercontent.com/missovo/XrayR-script/main/install.sh && bash install.sh)

#OR
bash <(curl -Ls https://raw.githubusercontent.com/missovo/XrayR-script/main/install.sh)

Bbr

1
bash <(curl -Lso- https://git.io/kernel.sh)

X-ui

1
bash <(curl -Ls https://raw.githubusercontent.com/vaxilu/x-ui/master/install.sh)

Git

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#配置同户名邮箱
git config --global user.name “xxx”
git config --global user.email “xxx@qq.com”

#克隆远程仓库
git clone https://github.com/xxxx.git

#添加当前目录文件
git add .

#提交说明
git commit -m '说明'

#更新到仓库
git push origin main

Hexo一键操作

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# 拉取仓库
git clone git@github.com:ghlsp/blog-admin.git

# 安装依赖
cd
cd blog-admin
rm -rf node_modules && npm install --force
hexo s

# 更新当前仓库
git add .
git commit -m "更新"
git push

# 清除缓存并本地预览
cd
cd blog-admin
hexo cl
hexo s

# 更新仓库
cd
cd blog-admin
hexo cl
git add .
git commit -m "更新版本号"
git push

服务器测速脚本

1
bash <(curl -Lso- https://git.io/superbench)

Linux(使用 UFW 防火墙)

1
2
3
4
5
# 完全禁用防火墙(清除规则且开机不启动)
sudo ufw disable

# 查看状态(显示 Status: inactive 即已关闭)
sudo ufw status

Linux(使用 firewalld 防火墙 - CentOS/RHEL)

1
2
3
4
5
6
7
8
# 停止防火墙服务
sudo systemctl stop firewalld

# 禁止开机自启
sudo systemctl disable firewalld

# 查看状态(Active: inactive 即已关闭)
sudo systemctl status firewalld