Follow the steps in rpush to add the gem to your rails project
rails g model PushNotificationDevice device_type:integer:index device_token:string
class CreatePushNotificationDevices < ActiveRecord::Migration
#SOLID Principles with ruby examples
##SRP - Single responsibility principle A class should have only a single responsibility.
Every class should have a single responsibility, and that responsibility should be entirely encapsulated. All its services should be narrowly aligned with that responsibility, this embrace the high cohesion.
##OCP - Open/closed principle Software entities should be open for extension, but closed for modification.