diff --git a/src/main/java/cokr/xit/foundation/boot/MvcConfig.java b/src/main/java/cokr/xit/foundation/boot/MvcConfig.java index 72c4dda..378728e 100644 --- a/src/main/java/cokr/xit/foundation/boot/MvcConfig.java +++ b/src/main/java/cokr/xit/foundation/boot/MvcConfig.java @@ -1,6 +1,9 @@ package cokr.xit.foundation.boot; +import javax.annotation.Resource; + import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.web.multipart.commons.CommonsMultipartResolver; @@ -24,6 +27,8 @@ import cokr.xit.foundation.web.AccessInitializer; @Configuration public class MvcConfig implements WebMvcConfigurer { protected static String[] URL_PATTERNS = {"/", "/**/*.do"}; + @Resource(name = "staticResource") + private StaticResourceConfig staticResource; /**AccessInitializer를 반환한다. * @return AccessInitializer @@ -33,6 +38,9 @@ public class MvcConfig implements WebMvcConfigurer { return new AccessInitializer(); } + @Value("${spring.web.resources.static-locations}") + private String staticLocations; + /**정적 파일 자원 접근에 대한 설정을 추가한다. *