Serve different static page depending of the server load


We are planning releasing a new web site shortly and we try to get

Our website is hosted with nginx, but I currently set the images of the
main page on amazon S3 as it won’t be able to serve them if we get
slash-dotted as planned.

To lower our cost, is there a way to tell nginx to serve for index.html
another file like index_local.html file when the load of the server is
and to serve index_aws.html when the load is high?

index_local.html would contain URL for images and an applet to the same
nginx file server but index_aws.html will set URL for them to S3.

If that is not possible, is there another way to do that? I don’t want
manually do the switch as we never know when the crowd come.



This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs