본문 바로가기
오류노트

Travis 빌드중 s3 접속시 Failed to open TCP connection 오류발생

by 어컴띵 2021. 4. 26.

Failed to open TCP connection to s3-url.s3.ap-northeast.amazonaws.com:443 (getaddrinfo: Name or service not known) (Seahorse::Client::NetworkingError)

 

Travis에서 s3접속해서 파일을 ec2에 전송하는 부분에서 오류가 발생하였다. 원인을 확인해보니 s3접속 주소중에 ap-northeast로 접속이 되는것이었다. 실제 s3주소는 ap-northeast-2였는데 말이다.

 

그래서 원인을 찾던중 .travis.yml파일의 deploy부분에서 region부분이 ap-northeast로 되어 있었다. 책에 있는 소스 그대로 입력하다보니 생긴 문제였다. 당연히 이부분은 ap-northeast-2로 수정하니 잘되었다.