codestates / codestates/Cityrunner
[AWS] Node.js 80포트 에러 해결방법
- Dominant language
- JavaScript
- Stars
- 2
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
> > ### 어떤 에러인가요?
>> 
>>
> > ### 에러 메시지
> > ```shell
> >Error: listen EACCES: permission denied 0.0.0.0:80
> > ```
> >
> >
> >
> >
> > ### 에러 핸들링 방법
> > AWS ec2 - ubuntu - Node.js를 사용하여 서버를 실행했을때 발생
> > * 80 포트를 사용하지 않고 8080포트 등 다른 포트를 사용하여 80 포트로 리디렉션
> >
> > ```shell
> > sudo iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080
> > ```
> >
> > ```shell
> > 추가 : [root@localhost~]# iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080
> >
> > 삭제 : [root@localhost~]# iptables -D PREROUTING -t nat -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080
> > ```
> > ```shell
> > iptables 저장 : [root@localhost~]# service iptables save
> >
> > iptables 확인 : [root@localhost~]# iptables -t nat -L
> >```
> >
> >
> >
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.