Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenGrider committed Jan 26, 2016
1 parent a1686e2 commit 2620706
Showing 1 changed file with 10 additions and 63 deletions.
73 changes: 10 additions & 63 deletions blog/apiserver/README.md
Original file line number Diff line number Diff line change
@@ -1,68 +1,15 @@
# ruby-getting-started
# Blog API

A barebones Rails app, which can easily be deployed to Heroku.
Run this locally if you want to have your own blog server.

This application support the [Getting Started with Ruby on Heroku](https://devcenter.heroku.com/articles/getting-started-with-ruby) article - check it out.

## Running Locally

Make sure you have Ruby installed. Also, install the [Heroku Toolbelt](https://toolbelt.heroku.com/).

```sh
$ git clone [email protected]:heroku/ruby-getting-started.git
$ cd ruby-getting-started
$ bundle install
$ bundle exec rake db:create db:migrate
$ heroku local
Setup
-----
In the project root, run the following:
```

Your app should now be running on [localhost:5000](http://localhost:5000/).

## Deploying to Heroku

```sh
$ heroku create
$ git push heroku master
$ heroku run rake db:migrate
$ heroku open
bundle
rake db:create
rake db:migrate
rails s
```

or

[![Deploy to Heroku](https://www.herokucdn.com/deploy/button.png)](https://heroku.com/deploy)

## Docker

The app can be run and tested using the [Heroku Docker CLI plugin](https://devcenter.heroku.com/articles/introduction-local-development-with-docker).

Make sure the plugin is installed:

heroku plugins:install heroku-docker

Configure Docker and Docker Compose:

heroku docker:init

And run the app locally:

docker-compose up web

The app will now be available on the Docker daemon IP on port 8080.

To work with the local database and do migrations, you can open a shell:

docker-compose run shell
bundle exec rake db:migrate

You can also use Docker to release to Heroku:

heroku create
heroku docker:release
heroku open

## Documentation

For more information about using Ruby on Heroku, see these Dev Center articles:

- [Ruby on Heroku](https://devcenter.heroku.com/categories/ruby)

And away you go!

0 comments on commit 2620706

Please sign in to comment.