diff --git a/whatsmars-spring-boot/src/main/java/com/itlong/whatsmars/spring/boot/config/AppConfig.java b/whatsmars-spring-boot/src/main/java/com/itlong/whatsmars/spring/boot/config/AppConfig.java index 15c5a165778c734532f9442e884abee2d743fde0..ebc9339021e5acc2fcc8c976841b2e94bf2d6f96 100644 --- a/whatsmars-spring-boot/src/main/java/com/itlong/whatsmars/spring/boot/config/AppConfig.java +++ b/whatsmars-spring-boot/src/main/java/com/itlong/whatsmars/spring/boot/config/AppConfig.java @@ -24,7 +24,7 @@ public class AppConfig { @Autowired private UserConfig userConfig; - @ConditionalOnProperty(value = "api.auth.enable") + @ConditionalOnProperty(value = "api.auth.enabled") @Profile({"dev", "prod"}) @Configuration public static class WebMvcConf extends WebMvcConfigurerAdapter { diff --git a/whatsmars-spring-boot/src/main/resources/application.yml b/whatsmars-spring-boot/src/main/resources/application.yml index 8251c3c9f124ca0031bd70236ba9890ec194dee6..310a5c236165d2b2bf240ad5809ece7325621613 100644 --- a/whatsmars-spring-boot/src/main/resources/application.yml +++ b/whatsmars-spring-boot/src/main/resources/application.yml @@ -27,6 +27,9 @@ security: api: auth: enabled: true +user: + welcome: Hello, World! + noFilterUrl: /,/login --- spring: @@ -58,9 +61,6 @@ server: pattern: common prefix: access_log suffix: .log -user: - welcome: Hello, World! - noFilterUrl: /,/login --- spring: @@ -92,9 +92,6 @@ server: pattern: common prefix: access_log suffix: .log -user: - welcome: Hello, World! - noFilterUrl: /,/login --- spring: @@ -125,7 +122,4 @@ server: enabled: true pattern: common prefix: access_log - suffix: .log -user: - welcome: Hello, World! - noFilterUrl: /,/login \ No newline at end of file + suffix: .log \ No newline at end of file