Set up free WordPress hosting using Amazon EC2 and Bitnami Cloud

Set up free WordPress hosting using Amazon EC2 and Bitnami Cloud

For a few months I had been contemplating on moving my blog to a separate server. Recent increase traffic it was receiving and many WordPress plugins I installed started to make it a bit sluggish. It had been hosted on a VPS along with few other sites.

If you have read my post about WordPress hosting for personal and small business, I listed Lightning Base with its Personal plan for only $9.95/month. After recommending it to a couple of clients, I am impressed with it as it is fast and running cPanel which I am very familiar with. It would be the finest choice with my requirements.

Amazon EC2

AWS EC2 Logo

Then I got my eyes on Amazon Web Services (AWS) with its Elastic Compute Cloud (EC2). It is basically a scalable cloud-based instance where you can increase or decrease its capacity almost instantly. Just like any other cloud based hosting provided. Its lowest instance t2.micro is priced at around $9.52/month and comes with 1 vCPU, 1GB RAM. More than enough for my needs at the moment. The wonderful thing is, AWS offers a [Free Tier] program where new customers can get started with Amazon EC2 for free for one year.

There was only one thing that held me back: like all other cloud based hosting services, EC2 requires deep knowledge of server (Linux) command line to set up everything. Of course AWS provides an extensive tutorial in how to set up WordPress on an EC2 instance, but it was still too much in my opinion since I needed something more practical.

Bitnami Cloud Hosting

Bitnami_logo_2013

The answer came in the form of Bitnami. It is an open source project that offers open source installers or software packages for web applications and development stacks. Over 100 open source application stacks are ready to use, including ever popular WordPress, Joomla, Magento, and more coming soon. I had known about Bitnami for a while, but I had not noticed about its Cloud Hosting product which was released in February 2010.

With Bitnami Cloud Hosting, you can monitor all your cloud servers and applications from one dashboard. Imagine being able to set up new WordPress blog on Amazon EC2 with a few clicks and less than 30 minutes. What is even greater, it comes with a free Developer Plan for one server (application).

Two essential components offered for free, no reason to hold me back from migrating my WordPress installation. The process went well, now I am ready to share with you the steps to set up yours.

Step 1: Create AWS Account

Just to be clear, EC2 is only one of dozens of AWS products and services. The AWS Free Tier program is free for 18 products/services within the limits defined by them. For EC2, you can run 750 hours (31 days = 744 hours) of Linux, RHEL, or SLES t2.micro instance usage per month.

Creating an AWS account is as simple as it can be. You just enter your personal data such as email, name, address and phone number. Note that you will need to enter a valid credit card information, but if you set everything right, you will not pay a dime until the following year. One next important step is automated phone validation but you only need to follow the on screen instructions and is very straightforward.

Step 2: Create Bitnami Cloud Hosting Account

This is much more simple and like most great web apps, creating an account is only a matter of minutes. You only need to enter basic data such as name, email and password. Click the link from the confirmation email, then you are all set. No credit card required until you need to add a second server/app.

Step 3: Add AWS as Bitnami Cloud Instance

We are now starting the fun part. First, you need to add your AWS account into Bitnami Cloud Hosting panel. Everything works through AWS’s API through its Access Key:

  1. Login to AWS Management Console
  2. From the console dashboard, click on your name on the top right and select Security Credentials
    AWS_Management_Console
  3. On “Your Security Credentials” page, click on Access Keys (Access Key ID and Secret Access Key) and then Create New Acess Key
  4. New Access Key ID and Secret Access Key strings will be automatically generated and displayed on your screen, copy and save it; you can also download the key file
    IAM Management Console

You are done from AWS side, next you need to share the access to Bitnami:

  1. Login to Bitnami Hosting
  2. From the left navigation, click on Clouds
  3. Under “Manage Cloud Accounts”, click New
  4. Enter the name and default location of your preference, for AWS Credentials enter the key strings generated from AWS then click Save

Bitnami Hosting now acts as the control panel of AWS and you can install application stacks on AWS through it.

Step 4: Spin WordPress from Bitnami Cloud

Next, let’s roll WordPress on AWS EC2 instance.

  1. From Bitnami’s panel, click Servers on the left navigation
  2. Under “Server Management”, click New and on the pop-up box select Launch Regular Server
  3. The next step involves selecting options:
    • Name: your server/application name, ie. “My Blog”
    • Domain Name: for every server you run on Bitnami, you need to create a subdomain under .bitnamiapp.com; you will be able to assign your own domain later
    • Application Options: enter admin login details and under Email Configuration you may also want to add your Gmail or Custom SMTP details
    • Development Options: the default components are enough, but I added Memcached and Varnish
    • Add New Application: click the button, search and tick on WordPress
    • Operating System: I just selected Ubuntu Linux (hvm) 64-bit
    • Server Type: T2 Micro
    • Disk Size: I just use 10GB, but AWS Free Tier allows you to use up to 30GB
    • Cloud Account: your AWS account name from step 2
    • Server Location: select from your preferred location, remember though that different location has different pricing after your Free Tier period expires
    • IP Address: you can select Dynamic IP or Static IP, I chose the latter
      Bitnami Hosting – New Server
  4. You can ignore the “Estimated Amazon charges” table because it is only Bitnami’s dynamic cost caculator; Amazon will not charge you if you only select the components within their Free Tier range
  5. Click Build and Launch

Now you just sit and wait for a few minutes for Bitnami to take care of things for you.

Step 5: Complete Your WordPress Site Installation

When your EC2 and WordPress installation is ready, you will receive an email from Bitnami. You can go into Bitnami Hosting panel and see your server under Servers. To customize or gain more information, click on the server name (eg. “My Blog”) and click Manage.

Some important items you may need to look at:

  1. Under Properties tab
    1. IP Address – this is the static or dynamic IP assigned to your server, you will need to enter the IP address on your DNS to point your domain to your server
    2. Application Credentials – if you did not assign a password of your application, it was automatically generated and can be retrieved here
  2. Under Applications tab, you want to change the address to your domain instead of a prefix under bitnamiapp.com subdomain; this will automatically linked to WordPress General Settings

Once you have updated your DNS to the IP of your WordPress installation and it has propagated, your site is ready and you can use it as you would install it from any server.

Additional Step: Optimize WordPress Installation

Out of the box, WordPress stack prepared by Bitnami is already good. Your website or blog will load blazingly fast. To some, including myself, it may not be enough though and you may want to make it even better. In that case, you want to read Bitnami’s excellent wiki page in how to optimize default WordPress install.


There you go. Free WordPress hosting for one year on a terrific cloud instance with less than an hour to set up. Do keep in mind that EC2’s t2.micro is probably ideal only if you have an average of few hundred up to low thousand page views per day. Above that, you may need to use their better instances although those are not eligible for AWS Free Tier program. If your blog is that popular, please be generous with your hosting budget.

18 Comments Set up free WordPress hosting using Amazon EC2 and Bitnami Cloud

  1. akshay

    Hi, MICHAEL
    Actually I stuck on the last part of changing the name server for my domain to the bitnami + AWS, I booked my domain by 1on1 domain, when I tried to change the IP address with the DNS in 1on1 its not changing, please resolve what am I doing wrong.

    Reply
    1. Michael

      Based on AWS Free Usage Tier FAQs: 15 GB of bandwidth out aggregated across all AWS services.

      Even let’s say you only get 1GB outgoing limit, I still think that’s quite a lot. If your blog/website is properly optimized and utilizes CDN, the combined HTML, CSS, JS size could be less than 200KB/page view. That’s 5,000 page views per month. If you actually get 15GB bandwidth, then it’s 75,000 page views per month or 2,500 per day. If you pass the included bandwidth, you only pay $0.09 per GB.

      At that point, I do not think you should be forcing yourself to use a free hosting as solution 🙂

      Reply
  2. anand

    Hi Michael,

    I would like to know that if i can move my current website which is in shared hosting can we moved to AWS using the above method?
    If so can you please let me know the instructions. Thank you very much for a helpful post.

    Reply
    1. Michael

      Hi Anand – Sorry I seem to miss your comment. Of course you can migrate your current WordPress site to another host. There are multiple methods and WP plugins that would allow you to do this. For starter, you should check out UpdraftPlus.

      You can use it to make full backup of your current WP installation, copy the backup files, then restore it on a clean WP installation on your new server.

      Reply
  3. Adrian Haurat

    Thanks for this informative post; it’s particularly helpful for someone who wants to start a new WordPress site from scratch on AWS. However, I have a WordPress site installation on my laptop. It’s set up as a git repository and I would like to push it to my new Bitnami AWS instance. I’m used to Ubuntu servers where I use git to pull the files onto the server and manually upload the database into MySQL, but this is my first time trying Bitnami. Is there a different process for getting my existing WordPress site set up on a Bitnami server?

    Reply
    1. Michael

      Hello Adrian – In your scenario, it is probably better not to install WordPress as additional application when you are creating a new server on Bitnami. Its default stack already includes Git installed. You can check this under “Development Options”. After the server is up and running, you can connect via SSH and pull the files from your repository.

      This is a bit off subject and personal preference, but I often feel it is quite difficult to keep your WordPress data consistent using repository once it goes live. It is easier to keep backups using a plugin such as UpdraftPlus or Duplicator. You can also use either of these plugins to migrate a site from one site to another quite easily.

      Reply
    1. Michael

      Hi Dan – You will be limited to only host one application/server using micro or small instance on EC2, which should be more than enough if you are hosting a small site or personal blog.

      Reply
  4. Pingback: How to create a free WordPress site on Amazon AWS EC2 without Terminal commands | cms

  5. Alex

    Hello, just a question. When you’re done with it, the wordpress has been installed in yourdomain.com/wordpress. How we can change it to the root domain yourdomain.com directly?

    Thanks

    Reply
    1. Michael

      Hi Alex – That’s quite easy. On Bitnami Cloud panel, you can click on Servers on the left, select the server name you just created, then click Manage. Select Applications tab, then click on the Edit (pencil) icon next to the current domain. It will pop up Update Application Custom Domain modal box. There you just change to Use Custom Domain and then update your domain DNS.

      Hope this helps. Let me know if you need further guidance.

      Reply
  6. Pingback: I have done blogs before | Mister Delaney

  7. AJ

    If I use the Free Tier for 1 year and use the wordpress along it for free.
    So if I continue the next year by buying the micro instance, will I also have to pay for using WordPress or is it included in the micro instance price.
    Thank You… 🙂

    Reply
    1. Michael

      Hi AJ – WordPress (not wordpress.com) is an open source application which could be installed on your own server. In the case of using Bitnami + AWS, you only need to pay for t2.micro instance starting on the second year. You will not need to pay monthly/annually for WordPress application itself.

      Hope this clears it up a bit.

      Reply

Leave a Reply