title: Deployment structure for Ruby on Rails application and amazon cloud service
body: <p>How to organize development lift-cycle?</p>
  
  <p>Yep, I understood that it's very difficult question; nevertheless I'm trying to find out the best way of organizing my development process among thousands articles/documentations and so on. However I'm afraid of painful mistakes that can lead to damages. </p>
  
  <p>There is a project; let's call it <code>titan</code>. This project was implemented on <code>Ruby on rails</code> and <code>postgresql</code> as database. Current structure is</p>
  
  <pre><code>[developer]-&gt;[dev-server]
               {
               (load-balancer)-&gt;app_server_1&lt;---write/read---&gt;Postgresql(master)         
                                                                  |
                                                                  |replication
                                                                  |
                              -&gt;app_server_2&lt;---read.only----&gt;Postgresql(slave)
               }
  </code></pre>
  
  <p>This is an expected structure of the application; this application is only for developers so it can not be accessed from Internet.
  And at this point arise first problems. I have an intention of deploying my app in amazon cloud service.  </p>
  
  <p>Of course I could create a virtual machines in cloud, copy project's files, configure all my staff, however it takes much time and moreover it sometimes leads to different problems and errors. 
  And I want to create environment for developers(me) that will help me to deploy my app by clicking on button. </p>
  
  <p>I think that there is software that can easily handle my tasks with deployment, but now I stuck with it. So there is the structure that will be suitable for me as I think</p>
  
  <pre><code>               [amazon]---------{
                    ^      (load-balancer)-&gt;app_server_1&lt;---write/read---&gt;Postgresql(master)   |     
                    |                                                        |
                    |                                                        |replication          |
                    |                                                        |
                    |                     -&gt;app_server_2&lt;---read.only----&gt;Postgresql(slave)    |
                    |
                    |    }
                    |(a)
  [developer]-&gt;[dev-server]
               {
               (load-balancer)-&gt;app_server_1&lt;---write/read---&gt;Postgresql(master)         
                                                                  |
                                                                  |replication
                                                                  |
                              -&gt;app_server_2&lt;---read.only----&gt;Postgresql(slave)
               }
  </code></pre>
  
  <p>And at the point <code>(a)</code> there is a number of questions. At this stage I want to test my app(unit testing), reconfigure according amazon's server configuration, change it status to <code>production</code>, but not a <code>dev</code>. And so on. 
  I hope that it should be a software that could help me to do it, or you'll leave me some helpful tips. </p>