Axios 서버에서 axios요청을 다른서버로 보낼시 에러(https)
NestJS(NodeJS)서버에서 다른 NestJS(NodeJS)서버로 GET요청을 할때 발생된 에러 입니다. 아래는 터미널 출력 내용입니다. Axios URL : https://goodgame:5000/users/single fetch error : AxiosError: unable to verify the first certificate at TLSSocket.onConnectSecure (node:_tls_wrap:1530:34) at TLSSocket.emit (node:events:394:28) at TLSSocket._finishInit (node:_tls_wrap:944:8) at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:725:12) { code: 'UNABLE_TO_VERIFY_LEAF_SIGNATURE', 위보다 훨씬 길었지만 중요한 것은 fetch error와 code입니다. 위 문제를 해결하기 위해서 axios에 코드를 추가해 줘야 합니다. const https = require ( 'https' ); const response = await axios . get ( process . env . NESTJS_RESTAPI_URL + '/users/single' , { headers : { 'Content-Type' : 'application/json' , authorization : 'Bearer ' + token , }, httpsAgent : new https . Agent ({ rejectUnauthorized : false , //허가되지 않은 인증을 reject하지 않...