Before adding a rule, ssh was working fine. For Jenkins, I added the custom tcp security group rule (8080) so i could access it. Then jenkins was working fine. Now, ssh does not.
Security Group rules screenshot
Even after removing the custom tcp which should restore the security group back to its original state, it does not ssh.
It gives ssh: connect to host ---.compute-1.amazonaws.com port 22: Connection timed out
NOTE: DO GUIDE ME IF SOMETHING IS MISSING OR NEEDS MORE EXPLANATION.