添加nacos日志开关,默认关闭,日志打开会导致写大量无用日志把硬盘占满

This commit is contained in:
361243819@qq.com 2021-10-12 14:39:32 +08:00
parent 385f03dbea
commit b3007e4ad7
2 changed files with 7 additions and 0 deletions

View File

@ -45,6 +45,7 @@ public class PigNacosApplication {
System.setProperty(ConfigConstants.STANDALONE_MODE, "true");
System.setProperty(ConfigConstants.AUTH_ENABLED, "false");
System.setProperty(ConfigConstants.LOG_BASEDIR, "logs");
System.setProperty(ConfigConstants.LOG_ENABLED, "false");
return true;
}

View File

@ -40,4 +40,10 @@ public interface ConfigConstants {
*/
String LOG_BASEDIR = "server.tomcat.basedir";
/**
* access_log日志开关
*/
String LOG_ENABLED = "server.tomcat.accesslog.enabled";
}