I can't connect to another EC2 instance in the same security group using public ip.
If I try to connect using public DNS name and private ip, it is working fine.
What I have done so far:
- created two EC2 public instances
- attached both instances to security group sg-12345
- added inbound rules
- all traffic, source=sg-12345
- SSH port=22, source= my ip (this is to login into my EC2 instance from my desktop)