centos与lotserver

本文提供了一键更换LotServer内核脚本的方法,详细介绍了LotServer的安装、卸载及常用命令。同时,文章还涵盖了V(2)Ray的安装、配置过程,包括设置Nginx代理,实现HTTPS加密传输,适用于需要快速搭建代理服务器的用户。

一键更换可用LotServer内核脚本

wget --no-check-certificate https://www.vrrmr.net/55R/CTOSneihe.sh && bash CTOSneihe.sh

出处

一键安装LotServer

安装
bash <(wget --no-check-certificate -qO- https://github.com/MoeClub/lotServer/raw/master/Install.sh) install
卸载
bash <(wget --no-check-certificate -qO- https://github.com/MoeClub/lotServer/raw/master/Install.sh) uninstall

出处

常用命令

启动命令 /appex/bin/lotServer.sh start
停止加速 /appex/bin/lotServer.sh stop
状态查询 /appex/bin/lotServer.sh status
重新启动 /appex/bin/lotServer.sh restart

关闭防火墙

systemctl stop firewalld.service

安装V(2)Ray

获取&设置
bash <(curl -L -s https://install.direct/go.sh)

systemctl enable v2ray      //自启
添加配置
echo "" > /etc/v2ray/config.json
vi /etc/v2ray/config.json
{
  "inbounds": [
    {
    "port":20552,
      "listen": "127.0.0.1", 
      "tag": "vmess-in", 
      "protocol": "vmess", 
      "settings": {
        "clients": [
          {
	  "id":"10ff7b1c-8394-4f2b-bec6-f218ff2df01a",
	  "alterId":4
          }
        ]
      }, 
      "streamSettings": {
        "network": "ws", 
        "wsSettings": {
	  "path":"/258b0696/"
        }
      }
    }
  ], 
  "outbounds": [
    {
      "protocol": "freedom", 
      "settings": { }, 
      "tag": "direct"
    }, 
    {
      "protocol": "blackhole", 
      "settings": { }, 
      "tag": "blocked"
    }
  ], 
  "routing": {
    "domainStrategy": "AsIs", 
    "rules": [
      {
        "type": "field", 
        "inboundTag": [
          "vmess-in"
        ], 
        "outboundTag": "direct"
      }
    ]
  }
}

安装Nginx

添加一个源
vi /etc/yum.repos.d/nginx.repo


[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/centos/7/$basearch/
gpgcheck=0
enabled=1
安装
yum -y install nginx

systemctl enable nginx		//自启
添加配置文件
vi /etc/nginx/conf/conf.d/v2ray.conf
server {
    listen 443 ssl;
    ssl_certificate       /data/v2ray.pem;
    ssl_certificate_key   /data/v2ray.key;
    ssl_protocols         TLSv1 TLSv1.1 TLSv1.2 TLSv1.3;
    ssl_ciphers           TLS13-AES-256-GCM-SHA384:TLS13-CHACHA20-POLY1305-SHA256:TLS13-AES-128-GCM-SHA256:TLS13-AES-128-CCM-8-SHA256:TLS13-AES-128-CCM-SHA256:EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+ECDSA+AES128:EECDH+aRSA+AES128:RSA+AES128:EECDH+ECDSA+AES256:EECDH+aRSA+AES256:RSA+AES256:EECDH+ECDSA+3DES:EECDH+aRSA+3DES:RSA+3DES:!MD5;
    server_name www.xghao.xyz;
    index index.html index.htm;
    root  /home/wwwroot/levis;
    error_page 400 = /400.html;
    location /258b0696/
    {
        proxy_redirect off;
        proxy_pass http://127.0.0.1:20552;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;
    }
}
server {
    listen 80;
    server_name www.xghao.xyz;
    return 301 https://www.xghao.xyz$request_uri;
}

最后

重启
systemctl restart v2ray
systemctl restart nginx
查看状态
systemctl status v2ray
systemctl status nginx

service nginx reload

PS

有问题私聊,该文章禁止评论!

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值