it will be a statelss applciation since we do not need any database:

you start with a basic public ec2:

Untitled

then incase that the public ec2 shutsdowno or any issue is predicted, u assign elastic IP to have fixed IP

Untitled

Now we will scale vertcially, the users icnreased and traffic increased hecne we scale vertically:

There will be downtime as we go from t2 to m5

Untitled

more users have increased npw and we need to add instnaces and this is where horiontal scaling comes in:

Untitled

but how do users know how to acces these different m5 instnaces via theri elastic IPs

firslty we will remove elasitc IPs, since there are only 5 elastic ips per region ****per account

hence mow users will access using route 53

it has record bczu using a dns it will reutrn list of ips

users will keep accessing via dns query, and will get m5 isntnace ke ips in return:

Untitled

then we decide to rmeove the isntance, and use ttl, this has problem bcuz ttl is one hour, and this will mean that the 730 users will not be able to access an instance a whole hour, and after that only will it be able to access it, we will have to find a better way to solve this

Untitled

now we move to private EC2 instnaces, in the same AZ

Untitled

the ELB will be then connected to a route 53, alias, bcuz since ELBs ip address keeps chanigng, an alias will ensure that it is connected to the elb using resource, and not reosure ka ip