공부하다죽어라
article thumbnail
Docker Failed to load any of the given libraries: [netty-tcnative-linux-x86_64,netty-tcnative]
개발/에러 해결 2021. 8. 13. 13:05

Jenkins를 통해 자동배포를 완료하고 빌드마저 정상적으로 작동되는 상황에서 Firestore와 관련한 서비스가 작동하지 않았던 이슈가 있었습니다. 관련 로그를 보면 Failed to load any of the given libraries: [netty-tcnative-linux-x86_64,netty-tcnative] 라는 문구가 뜨네요 - 해결방법 도커에서 이미지파일을 만들때 FROM openjdk:8-jdk-alpine ARG JAR_FILE=target/*.jar COPY ${JAR_FILE} curation.jar ENTRYPOINT ["java","-jar","/curation.jar"] 위 파일을 FROM koosiedemoer/netty-tcnative-alpine ARG JAR_FIL..

article thumbnail
Unknown lifecycle phase ".run.profiles=local". 오류 해결
개발/에러 해결 2021. 7. 23. 15:06

해결방법 mvn spring-boot:run -D"spring-boot.run.profiles"=local - stackoverflow https://stackoverflow.com/questions/60758633/unable-to-set-command-line-profile-in-spring-boot-2-2

article thumbnail
Spring boot CORS Response Header값이 넘어오지 않는 이슈
개발/에러 해결 2021. 7. 14. 00:13

스프링 시큐리티를 이용한 로그인 구현 중 Vue.JS에서 JWT로 발행된 토큰값을 헤더에 넣어서 보냈는데 어찌된 영문인지 포스트맨에서는 정상적으로 출력되지만 CORS 환경에서는 헤더 값이 제대로 반환되지 않는 이슈를 겪었습니다. 결론은 클라이언트 잘못이 아니고 서버측에서 CORS에 대해 exposedHeaders를 따로 설정해줘야 했던 문제였습니다. @Configuration public class WebConfig implements WebMvcConfigurer { @Override public void addCorsMappings(CorsRegistry registry) { registry.addMapping("/**") .allowedOrigins("http://localhost:8080") .e..

article thumbnail
Spring Security no instance(s) of type variable(s) exist so that UserService conforms to UserDetailsService 에러
개발/에러 해결 2021. 6. 18. 09:57

Spring Security를 이용한 로그인처리를 구현하던 도중 만나게 된 에러입니다. no instance(s) of type variable(s) exist so that UserService conforms to UserDetailsService 자세히 보니 userService에 UserDetailsService를 상속받지 않고 그냥 SecurityConfig에 권한 검증 설정만 해둬서 생긴 문제였습니다.. 바로 상속받고 구현해줬습니다. @Override public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException { UserEntity userEntity = userRepository.findByEm..