typeomr 연결 설정으로 entity 경로 설정 시 entity를 찾지 못하는 문제
const entitiesPath = path.join(process.cwd() + '/**/*.entity.{ts,js}');
entities: [entitiesPath],
entity의 경로를 적어주었는데, entity 경로를 파악하지 못함.
__dirname
을 콘솔에 출력한 결과 현재 경로가 프로젝트 루트의 dist 폴더 안으로 출력되고 있었음
__dirname
의 경로가 프로젝트 루트의 dist 경로로 포함되어서 나와서
const entitiesPath = path.join(process.cwd() + '/dist/**/*.entity.{ts,js}');
경로에 /dist를 추가하고 해결되었음.
현재경로가 왜 dist로 시작되는지 모르겠지만, nest start 명령어로 프로젝트 실행 시 dist 경로에서 이루어지는 듯 함