IntelliJ IDEA license server搭建


本文用于搭建JetBrains系列软件激活服务器,如有能力,请支持正版
##准备

  • Centos 7
  • Nginx
  • 适用于JetBrains系列

##安装nginx

1
2
3
4
yum install epel-release
yum -y install nginx
service nginx start
systemctl enable nginx

nginx配置

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
server {
listen 主机IP:端口port;
# 需要自己配置 例: 123.33.32.23:8888
# listen [::]:8888 default_server ipv6only=on ;
server_name localhost;
root /usr/share/nginx/html;

# Load configuration files for the default server block.
include /etc/nginx/default.d/*.conf;

location / {
# 反向代理
proxy_pass http://idea.lanyus.com:80;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}


error_page 404 /404.html;
location = /40x.html {
}

error_page 500 502 503 504 /50x.html;
location = /50x.html {
}
}

重启nginx,加载配置

查看nginx主进程

ps -aux |grep nginx

master 为主进程,使用kill -HUP 777平滑重启

kill -HUP 777

配置防火墙

centos7默认安装了firewalld,若没有安装,执行yum install firewalld firewalld-config安装

systemctl start firewalld  # 启动

打开监听端口(上文绑定端口ip:port

firewall-cmd --zone=public --add-port=8080/tcp --permanent // 永久开启8080端口

重新加载防火墙

 firewall-cmd --reload

现在可以使用你的ip:port激活


文章作者: 苏叶新城
版权声明: 本博客所有文章除特別声明外,均采用 CC BY 4.0 许可协议。转载请注明来源 苏叶新城 !
  目录