This is an easy way to set up your own version of PageOneX in Heroku, and make the process easier than in the last post about this topic.
Heroku is a free hosting service to test web apps. The free service allows you to run your app with a limit in its data base.
If something is not clear, ask in the comments. We’ll updating this post.
You’ll need:
Let’s say you want to create your app named “pageonextesterx”. It will have the url: http://pageonextesterx.herokuapp.com.  “pageonextesterx” must be an unique name, no other app should have your chosen name. So change it!
Run the following commands in a terminal (tested with ubuntu)
git clone git@heroku.com:pageonex.git
It clones (downloads) the files for the deployment. You can also download them from: http://pageonex.com/pageonextester-heroku-1.0.1.zip
Create your app at Heroku:
heroku create pageonextesterx
For this you’ll have had to create your own Heroku account before and choose a name that no one has taken before.
Go into the created folder.
cd pageonex
Edit the git config file at .git/config
nano .git/config
or use
gedit .git/config
The file will open in the “nano” editor or “gedit” editor. You can also go to the hidden folder .git and open the “config” file.
Once inside you have to change “git@heroku.com:pageonex.git” by “git@heroku.com:pageonextesterx.git”. This will tell Git where to upload your files. If you try to upload (push) to “git@heroku.com:pageonex.git” you will not have the rights to do it.
Now you are ready to upload your app:
git push heroku master
You will need to upload your ssh key to heroku. You can find it (in ubuntu) at /home/.ssh/id_rsa.pub, and have to copy paste in your heroku account settings page.
To view hidden files you have to activate view of hidden files.
It will upload your files to your deployment. Now you need to run more commands:
heroku run rake db:migrate --app pageonextesterx
We are adding “–app pageonextesterx” is to specify which of the apps that you have it’s being used.
heroku run rake scraping:kiosko_names --app pageonextesterx
Go to http://pageonextesterx.herokuapp.com. You are ready to go!
Note: We hope to have soon our own deployment running at pageonex.com, so you don’t have to install your own. We are providing you with this manual to help run your own deployment. Running it in your computer is more difficult than doing it remotely in eroku, as you do no have to install rails, ruby or the gems associated with the project.

7 thoughts on “The easy way to run your own PageOneX deployment in heroku

  1. Pingback: numeroteca » The easy way to run your own PageOneX deployment in heroku

  2. Sorry about the dead link.

    I haven’t tested it in Heroku recently but it should work. To make a light installation (and not download the images) check in the wiki https://github.com/numeroteca/pageonex/wiki#switch-between-embedding-image-files-from-kioskonet-or-storing-locally:
    Change value to false at config/initializers/application.rb:
    Pageonex::Application.config.use_local_images = true

    Check the wiki Developer section for more updated details on how t odeploy it.

    If the most recent version doesn’t work in heroku, please report here, and I can rescue an old one that works with the instructions posted in this post.

    Reply
    • We tried with the origin/master branch and the origin/heroku branch with no luck.

      We get the following message


      heroku run rake db:migrate --app d4pageonex --trace
      Running `rake db:migrate --trace` attached to terminal... up, run.5808
      DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/01/04/rails-3-2-0-rc2-has-been-released. (called from at /app/Rakefile:7)
      DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/01/04/rails-3-2-0-rc2-has-been-released. (called from at /app/Rakefile:7)
      rake aborted!
      cannot load such file -- nokogiri
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in `require'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in `block in require'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:236:in `load_dependency'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in `require'
      /app/lib/tasks/scraping.rake:3:in `'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:245:in `load'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:245:in `block in load'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:236:in `load_dependency'
      /app/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:245:in `load'
      /app/vendor/bundle/ruby/2.0.0/gems/railties-3.2.2/lib/rails/engine.rb:425:in `block in load_tasks'
      /app/vendor/bundle/ruby/2.0.0/gems/railties-3.2.2/lib/rails/engine.rb:425:in `each'
      /app/vendor/bundle/ruby/2.0.0/gems/railties-3.2.2/lib/rails/engine.rb:425:in `load_tasks'
      /app/vendor/bundle/ruby/2.0.0/gems/railties-3.2.2/lib/rails/application.rb:145:in `load_tasks'
      /app/vendor/bundle/ruby/2.0.0/gems/railties-3.2.2/lib/rails/railtie/configurable.rb:30:in `method_missing'
      /app/Rakefile:7:in `'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in `load'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in `load_rakefile'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:501:in `raw_load_rakefile'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:82:in `block in load_rakefile'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:81:in `load_rakefile'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:65:in `block in run'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
      /app/vendor/bundle/ruby/2.0.0/gems/rake-0.9.2.2/bin/rake:33:in `'
      /app/vendor/bundle/ruby/2.0.0/bin/rake:23:in `load'
      /app/vendor/bundle/ruby/2.0.0/bin/rake:23:in `'

      Reply

Leave a reply

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> 

required