added checks for EC2 private IP and hostname on instances