스프링부트
![[Spring] Swagger 연동 시 Unable to infer base url 접속 에러 (ResponseBodyAdvice)](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FtLlAe%2FbtrJvQMVeKT%2F9K9A8bBfVQqZipfKLtcez0%2Fimg.png)
[Spring] Swagger 연동 시 Unable to infer base url 접속 에러 (ResponseBodyAdvice)
Unable to infer base url. This is common when using dynamic servlet registration or when the API is behind an API Gateway. The base url is the root of where all the swagger resources are served. For e.g. if the api is available at http://example.org/api/v2/api-docs then the base url is http://example.org/api/. Please enter the location manually: 스웨거 사용 중인 스프링 부트 서버에서 기능 업그레이드 중 갑작스럽게 나타난 에러 원래는 ..
![[Spring] 스프링 부트 프로젝트에서 dotenv 환경변수 파일 사용하기](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FpPPWR%2FbtrIPX7avcP%2FKz7tSJ5sUOUpxhdSM73xN0%2Fimg.png)
[Spring] 스프링 부트 프로젝트에서 dotenv 환경변수 파일 사용하기
스프링 프레임워크를 사용하는 웹앱 프로젝트를 진행하면서 환경변수를 저장하기 위한 방법을 검색해보았다 그런데 보통 .env.properties 파일을 만들어서 그 안에 있는 값을 또 프로퍼티 빈을 만들어서 불러오더라 이렇게 하더라도 비밀키 값 같은 거는 .gitignore 에다가 등록을 하면 되지만 다른 언어를 사용하다가 온 입장에서는 굳이 이렇게 해야하나 싶어서 뭔가 답답하다고 해야하나 그래서 이 프로젝트에서는 .env 파일을 사용해서 환경변수를 불러오는 방법을 도입시켜보았다 📝 /.env PORT=8000 JWT_SECRET_KEY="MYSUPERSECRETJWTKEY" ... 우선 프로젝트 루트 디렉토리에 .env 파일을 만들었다 📝 /.gitignore ... .env* git을 사용중이라면 반드시..