Amazon EC2 Multi Domain Setup and Technology Behind 9lessons
Wall Script
Follow Me:
Monday, December 26, 2011

Amazon EC2 Multi Domain Setup and Technology Behind 9lessons

Recent days I received lots for requests from my readers that asked to me few questions about 9lessons.info hosting and CMS technology. This post explains you how do I setup my domains + sub domains with Blogger and Amazon EC2 hosting. How to setup multi domains setup in Amazon Elastic Compute Cloud using htaccess file.

Amazon EC2 Multi Domain Setup


Why Blogger
It's powerful, fast and it is Google's product. 9lessons.info powered my many cloud services picasa for images, download scripts by box.net and revenue by Google adsense
Amazon EC2 Multi Domain Setup


Domain Redirection
.htacces code for redirecting 9lessons.info to www.9lessons.info
RewriteEngine On
RewriteCond %{HTTP_HOST} ^9lessons.info
RewriteRule (.*) http://www.9lessons.info/$1 [R=301,L]

Sub Domain Redirection
Sub domain redirection mapping to folder. Here demos.9lessons.info connecting to demos folders.
RewriteCond %{HTTP_HOST} ^demos\.9lessons\.info$
RewriteCond %{REQUEST_URI} !^/demos/
RewriteRule (.*) /demos/$1

RewriteCond %{HTTP_HOST} ^labs\.9lessons\.info$
RewriteCond %{REQUEST_URI} !^/labs/
RewriteRule (.*) /labs/$1

Godaddy DNS Settings
Godaddy DNS settings

Other Domain
Same way third party domain redirection.
RewriteEngine On
RewriteCond %{HTTP_HOST} ^androidhive.info
RewriteRule (.*) http://www.androidhive.info/$1 [R=301,L]

RewriteCond %{HTTP_HOST} ^www\.androidhive\.info$
RewriteCond %{REQUEST_URI} !^/androidhive/
RewriteRule (.*) /androidhive/$1

Elastic IP Redirection
IP redirection to www.9lessons.info
<script>
window.location.href = "http://www.9lessons.info/";
</script>

My Favorite Tools and Fonts
Specially I love hand drawing effects. I'm using Adobe Illustrator and Photoshop for designing banners and here my favorite fonts.
Amazon EC2 Multi Domain Setup

Download Fonts
Was this article helpful?
Thanks! Your feedback helps us to improve 9lessons.info


36 comments:

  1. You didn't included Helvetica in the Download List :(

    ReplyDelete
  2. can i host one of my blogger sub-domain on wordpress with Amazon EC2? what are the pricing for Amazon EC2?

    ReplyDelete
  3. Its always good to use Blogger, many awesome options are available including custom domain name registration.

    ReplyDelete
  4. Better switch away from Go daddy hosting or else you visitors will switch away from your blog.
    How can you still be on go daddy ( fools supporting SOPA) while the whole world is switching.

    ReplyDelete
  5. I think i too wanna go for Amazon EC2

    ReplyDelete
  6. @designs: Helvetica is part of all operating systems, don't need to downwload...

    ReplyDelete
  7. Disappointing to see that you are still with godaddy...

    ReplyDelete
  8. Can you please help in one issue?
    1. I have successfully done so that [mydomain.net] points to my EC2 server.
    2. Also in turns [mydomain.net] into [www.mydomain.net].
    3. Even I've done so that it go [www/demos] when request [demos.mydomain.net]

    But I have a blog [myname.blogspot.com]. What should I do so that [www.mydomain.net] points to [myname.blogspot.com]?

    I have added CNAME [www]---[ghs.google.com] in DNS manager.

    Can you please assist?

    ReplyDelete
  9. Hi Nuhil

    Go to blogger blog Settings -> Publishing add your custom domain

    ReplyDelete
  10. I have my blog on tumblr. Would it be wise to move it to blogger. I think tumblr doesn't have a great text editor like for writing the scripts in colors. What do you say? Please reply.

    ReplyDelete
  11. How do you fix up templating on blogger?

    ReplyDelete
  12. Waiting for this post since long ago. I will must do it for my blog. thanks for share this great tech behing 9lessons.

    ReplyDelete
  13. Dear Srini,

    Y do you use .htaccess to control all your subdomain forwarding? you could still do it at goDaddy/any DNS manager itself.

    ReplyDelete
  14. I mean by using virtual host instead of .htaccess

    ReplyDelete
  15. hi srinivas, can you please post a detailed tutorial on how to configure subdomains with webhosting? actually the word called ".htaccess" and how to implement this seems to be very unknown for a non-techie kind of person like me. I would be glad if you could help me out in this regard. Thanks

    ReplyDelete
  16. Technology show good results, it always a best deal of getting new idea.

    ReplyDelete
  17. If blogger.com provide me free hosting so why should I use amazon cloud?
    Will blogger.com give this service in huge traffic flow?
    I am waiting for your valuable answer.
    Thanks for this valuable post. You are always rockzz :-)

    ReplyDelete
  18. it very useful system wit large web pages. thank you

    ReplyDelete
  19. Thanks for sharing this!
    I'm planning to use Blogger and Amazon EC2.

    ReplyDelete
  20. Hi

    First of all what is the link to Amazon EC2 ?

    And with what you wrote can i upload my php mysql file on the server with my design ? Is it like a hosting where i can upload my website ?

    ReplyDelete
  21. Thank you for sharing the wonderful information.

    ReplyDelete
  22. What do u use to show demos ??

    ReplyDelete
  23. @sathesh, He use Amazon EC2 for demo purpose

    ReplyDelete
  24. Hi im new to web how the articles will be stored in your database(My SQL) or Google Database ?

    ReplyDelete
  25. I learned a better way, just change the httpd.conf

    On ssh:
    $ sudo vi /etc/apache2/httpd.conf

    Then, put
    --------

    Servername domain1.com
    DocumentRoot /var/www/domain1


    Servername domain2.com
    DocumentRoot /var/www/domain2

    ---

    Just it, done ;)

    ReplyDelete
  26. What is banifit of this type domain mapping.Would you please help me because i am new for this and i don't know anything about it.

    ReplyDelete
  27. in which file do we add RewriteEngine On
    RewriteCond %{HTTP_HOST} ^9lessons.info
    RewriteRule (.*) http://www.9lessons.info/$1 [R=301,L] code and how

    ReplyDelete
  28. great tutorial... This information really helpful..but when youtube(bangladesh) blocked.it has effected blogger service...so blogger or own hosting, which is the best?thanks

    ReplyDelete
  29. Hi,

    First of all what is the link to Amazon EC2 ?

    And with what you wrote can i upload my php mysql file on the server with my design ? Is it like a hosting where i can upload my website ?

    ReplyDelete

Make in India