Web server running on IPv6-only instance not reachable from Internet

0

My instance is running in a dual-stack VPC with a public subnet. It has a public IPv6 address (but no public IPv4). The instance runs a web server listening on port 4433. The attached security group has rules to allow inbound traffic on :4433 from 0.0.0.0/0 and from ::/0. The VPC has a NAT64 gateway to allow IPv6 instances to connect to external IPv4-only services.

Connecting to the instance via SSH works fine using: ssh -6 ubuntu@INSTANCE_PUBLIC_IPV6_ADDRESS but trying to access the web server via a browser as https://[INSTANCE_PUBLIC_IPV6_ADDRESS]:4433/ fails with ERR_CONNECTION_REFUSED. I also have a Route53 AAAA record (mysub.mydom.com) resolving to the IPv6 address but https://mysub.mydom.com:4433/ fails the same way.

2개 답변
1
수락된 답변

Hello.

Is your web server (such as Nginx) configured to listen to IPv6?
I suspect that the web server settings are only allowing it to listen on IPv4.
https://docs.aws.amazon.com/lightsail/latest/userguide/amazon-lightsail-configure-ipv6-on-nginx.html

profile picture
전문가
답변함 2달 전
profile picture
전문가
검토됨 2달 전
profile pictureAWS
전문가
검토됨 2달 전
0

Thank you for the pointer! That was indeed the issue. I'm not using nginx (yet), just allowing direct access to the app via a WSGI server. I didn't realize you must explicitly tell uwsgi to listen for IPv6 hosts: uwsgi --https [::]:$PORT,$SSL_CERT_PATH,$SSL_KEY_PATH --socket /tmp/app.sock --mount ...

Vas
답변함 2달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠