Client only connects to local dedicated server

I’ve created a simple dedicated server by following the dedicated server documentation and it works perfectly when the client is on the same machine as the server. The client connects with ClientTravel("127.0.0.1:7777, …), all works well.

Once I move the server on another machine (actually an aws ec2 host), i try to connect the client with ClientTravel(“[ec2ip]:7777”, …) but there’s no connection attempt in the server log.

The ec2 machine has an inbound rule for port 7777 in the firewall.

I’ve tested with a non-unreal project (the client-server example in aws) and it works, so the ec2 machine port is properly set-up.

What could cause the problem?