新增B站直播相关配置
新增MySQL及Redis配置 新增VUE前端
This commit is contained in:
@@ -1,8 +1,11 @@
|
||||
package com.yutou.tools.nas;
|
||||
|
||||
import com.yutou.tools.mybatis.dao.UKeyDao;
|
||||
import com.yutou.tools.mybatis.model.UKey;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.File;
|
||||
@@ -15,7 +18,6 @@ import java.util.regex.Pattern;
|
||||
|
||||
@Controller
|
||||
public class UpdateIp {
|
||||
private static final String nasToken = "zIrsh9TUZP2lfRW753PannG49E7VJvor";
|
||||
private static List<String> keys = new ArrayList<>();
|
||||
|
||||
/* static {
|
||||
@@ -27,12 +29,10 @@ public class UpdateIp {
|
||||
keys.add("nas-ftp-server");
|
||||
}*/
|
||||
|
||||
|
||||
@RequestMapping("/nas/updateip.do")
|
||||
public void updateIp(String token, String ip) {
|
||||
if (!nasToken.equals(token)) {
|
||||
System.out.println("验证不通过:" + token);
|
||||
return;
|
||||
}
|
||||
public void updateIp(String ip) {
|
||||
|
||||
updateList();
|
||||
File file = new File("/etc/nginx/nginx.conf");
|
||||
if (file.exists()) {
|
||||
@@ -102,6 +102,5 @@ public class UpdateIp {
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
new UpdateIp().updateIp(nasToken, "119.119.120.99");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user