anchor.diff:  
   <%=vars.GSG_intro_sentence%>
   
  -This guide is intended to walk you through deploying a Ruby on Rails (RoR) app to <%=vars.product_full%>. If you experience a problem following the steps below, check the <%=vars.known_issues%> topic, or refer to the [Troubleshooting Application Deployment and Health](./../../devguide/deploy-apps/troubleshoot-app-health.html) topic.
  -
  -<p class="tip"><strong>Sample App Step</strong><br />If you want to go through this tutorial using the sample app, run <code>git clone https://github.com/cloudfoundry-samples/rails_sample_app</code> to clone the <code>rails_sample_app</code> from GitHub, and follow the instructions in the Sample App Step sections.</p>
  +This guide walks you through deploying a Ruby on Rails (RoR) app to <%=vars.product_full%>.
   
   <p class="note"><strong>Note</strong>: Ensure that your RoR app runs locally before continuing with this procedure.</p>
   
   ## <a id='deploy-yourapp'></a>Deploy a RoR Application ##
   
  -This section describes how to deploy a RoR application to <%=vars.product_short%>, and uses output from a sample app to show specific steps of the deployment process.
  -
   ### Prerequisites ###
   
  -* A Rails 4.x app that runs locally on your workstation
  +* A Rails 4.x app that runs locally
   * [Bundler](http://bundler.io) configured on your workstation
   * Intermediate to advanced RoR knowledge
   * The [cf Command Line Interface (CLI)](../../devguide/installcf/install-go-cli.html)
   - (**Optional**) Robust production web server for Ruby and RoR apps, such as Unicorn
   
  -### Step 1: Add the rails_12factor Gem to Your Gemfile ###
  +### Step 1: Configure Automatically Invoked Rake Tasks for Deployed Applications ###
   
  -1. Add `gem 'rails_12factor', group: :production` to your Gemfile.
  +For <%=vars.product_short%> to automatically invoke a Rake task while an app is deployed, you must:
   
  -    <p class="note"><strong>Note</strong>: This gem includes the <code>rails&#095;serve&#095;static&#095;assets</code> gem that enables your Rails app to run in production with the static assets serving functionality. The <code>rails&#095;serve&#095;static&#095;assets</code> gem does this by automatically modifying the <code>config.serve&#095;static&#095;assets</code> configuration parameter from <code>false</code> to <code>true</code>. Do not change the value for this option. For more information, refer to the <a href="https://github.com/heroku/rails_12factor">Rails_12factor GitHub README</a>.</p>
  + * include the Rake task in your app, and
  + * configure the application start command using the `command` attribute in the application manifest.
   
  -1. Run `bundle install` to update your Gemfile.
  +The following is an example of how to invoke a Rake database migration task at application startup.
   
  -<p class="tip"><strong>Sample App Step</strong><br />You can skip this step. This gem is already included in the <code>rails_sample_app</code> Gemfile.</p>
  -
  -### Step 2: (Optional) Configure Automatically Invoked Rake Tasks for Deployed Applications ###
  -
  -<%=vars.product_short%> does not provide a way to run a Rake task on a deployed application. For <%=vars.product_short%> to automatically invoke a Rake task while an app is deployed, you must include the Rake task in your application and also configure the application start command with the `command` attribute in the application manifest, `manifest.yml`.
  -The following is an example of how to invoke a Rake database migration task at application startup.
  +<p class="Note"><strong>Note</strong>: If your application does not require any Rake tasks, skip this step.</p>
   
   1. Create a file with the Rake task name and the extension `.rake`, and store it in the `lib/tasks` directory of your application.
   
  
positive.code:       command: bundle exec rake cf:on_first_instance db:migrate && rails s -p $PORT
      </pre>
  
  <p class="tip"><strong>Sample App Step</strong><br />You can skip this step. The <code>rails_sample_app</code> has no Rake tasks.</p>
  
  ### Step 3: Create and Bind a Service Instance for a RoR Application ###
  
  This section describes using the CLI to configure a PostgreSQL managed service instance for an app. <%=vars.dev_console_1%>
  
  <%=vars.product_short%> supports two types of service instances:
  
  * Managed services integrate with <%=vars.product_short%> through service brokers that offer services and plans and manage the service calls between <%=vars.product_short%> and a service provider.
  * User-provided service instances enable you to connect your application to pre-provisioned external service instances.
  
  For more information on creating and using service instances, refer to the [Services Overview](./../../devguide/services/index.html) topic.
  
  #### Create a Service Instance ####
  
  
negative.code: 
  If you want to view log activity while the app deploys, launch a new terminal window and run `cf logs [APP-NAME]`.
  
  In the terminal output of the `cf push` command, the `urls` field of the `App started` block contains the app URL. This is the `HOST_NAME` you specified with the `-n` flag plus the domain `<%=vars.app_domain%>`. Once your app deploys, use this URL to access the app online.
  
  
  ##<a id="next"></a>Next Steps ##
  
  You’ve deployed an app to <%=vars.product_short%>! Consult the sections below for information about what to do next.
  
  ###<a id="test"></a> Test a Deployed App ###
  
  Use the `cf` <%=vars.dev_console_2%> to review information and administer your app and your <%=vars.product_short%> account. For example, you could edit the `manifest.yml` to increase the number of app instances from 1 to 3, and redeploy the app with a new app name and host name.
  
  See the [Manage Your Application with the cf CLI](#cli-manage) section for more information. <%=vars.dev_console_4%>
  
  ### <a id='cli-manage'></a>Manage Your Application with the cf CLI ###
  
  Run `cf help` to view a complete list of commands, grouped by task categories, and run `cf help [COMMAND]` for detailed information about a specific command. For more information about using the `cf` CLI, refer to the cf Command Line Interface (CLI) topics, especially the <%=vars.cli_v6%> topic.
  
  