https-git-frp.conf 1.1 KB

12345678910111213141516171819202122232425262728
  1. # frpHTTPS
  2. server {
  3. #SSL 访问端口号为 443
  4. listen 443 ssl;
  5. #填写绑定证书的域名
  6. server_name git.caner.top;
  7. #文件大小限制
  8. client_max_body_size 200m;
  9. #证书文件名称
  10. ssl_certificate "/var/www/pki/git.caner.top_bundle.crt";
  11. #私钥文件名称
  12. ssl_certificate_key "/var/www/pki/git.caner.top.key";
  13. ssl_session_timeout 5m;
  14. #请按照以下协议配置
  15. ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  16. #请按照以下套件配置,配置加密套件,写法遵循 openssl 标准。
  17. ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
  18. ssl_prefer_server_ciphers on;
  19. server_tokens off;
  20. # 拦截所有请求
  21. location / {
  22. proxy_http_version 1.1; #代理使用的http协议
  23. proxy_set_header Host $host; #header添加请求host信息
  24. proxy_set_header X-Real-IP $remote_addr; # header增加请求来源IP信息
  25. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # 增加代理记录
  26. proxy_pass http://127.0.0.1:30000; #服务A访问地址
  27. }
  28. }