Allow HTTP/HTTPS

When you deploy an application on your server, you might want it accessible via a browser, either via HTTP or HTTPS. To do that, you need ingress rules in a security group to allow communication on port 80 (HTTP) and port 443 (HTTPS).

  • Create a new security group called frontend
  • Add a first rule: INGRESS, TCP, CIDR 0.0.0.0/0, port 80-80
  • Add another rule: INGRESS, TCP, CIDR 0.0.0.0/0, port 443-443

Now the instances using this security group will allow traffic from any IP (CIDR 0.0.0.0/0) on port 80 and 443.

Frontend Security Group

Add this Security Group to the instance that will be accessed via HTTP and HTTPS.

NOTE
If your instance only has this Security Group, you will not be able to access it via SSH.