Select Page

Author: Darren Cato

Export your postgress data from Heroku to Openshift

I’ve been considering moving my part-time startup application from Heroku to Openshift for some time now. Heroku is a great platform, but I could forsee the startup costs spiraling out of control long before I could start making any money from my product. I also dont feel as far removed from the infrastructure with openshift. Perhaps I’ll write another blog post about the merits of Open-shift, but for now here are the steps for migrating your Postgress data¬† which I hope may save some people some extra googleing. Step 1. Get the data from heroku $ heroku pgbackups:capture $ curl -o latest.dump `heroku pgbackups:url --app my-app-name` Step 2. Enable Openshift’s port forwarding $ rhc port-forward -a my-app-name --namespace my-domain Step 3. Export the data! $ pg_restore --host 127.0.0.1 --port 0000 --username "db-username" --dbname "-db-name" --no-password -clean no-acl -no-owner --schema public --verbose "latest.dump" Like this:Like...

Read More

Book Review: Instant RSpec Test-Driven Development How-to

Title: Instant RSpec Test-Driven Development How-to Author: Charles Feduke Publisher: Packt Publishing Release Date: June 25, 2013 Format: ePub Pages: 55 Source: Safari Books Online Weighing in at only 55 pages, Instant Rspec gets the reader up to speed very quickly with the rspec domain language. There is zero waste in the book. The author does not even bother to define rspec. He starts off with a brief overview of TDD then jumps right into installing rspec. The code examples are clear and concise. The console screenshots in chapter 1 were so pretty that I was enticed into finally setting up z-shell and pimping my own console. The book prefixed each chapter with simple, intermediate or advanced to indicate the comprehension level of the content. This really helped with reading speed as I tended to gloss over the simple concepts and I prepared myself mentally for the intermediate and advanced concepts. Overall the book was well written. The chapter on mocking could use a bit more clarification but that’s nothing a bit of Googling and stack overflow can’t fix. It took me a weekend to read this book. That’s a normal weekend with a family and all the responsibilities that comes with one. This book can easily be read within an hour or two in one sitting. If you want to get started with rspec testing or need a...

Read More

The perfect home media server / client setup

For several years now I’ve been on what seems to be a never ending quest to find the perfection media center setup. As technology and the times change, so do my requirements. My latest media client is the vizio costar google tv. Its a great little device for streaming media. Access to the android market, a full chrome flash enabled browser and a $99 price tag makes it the most capable and cost effective device on the market today. I’ve had this device for some time now and I’m really enjoying it. However since i gave my httpc the boot, my 1 terabyte external usb disk has been sitting idle along with all my archived media. I set out to change all this by creating a server. I just so happened to have a fanless ssd machine laying aroud that could fullfull just such a need. My goals are to Install Ubuntu Set up file sharing – serve up media files Setup a plex server – manage and decode video files Setup ssh server – remote administration Setup vnc server – remote visual adminitration Install a good torrent applicaton – you never know Installing Ubuntu Lets start with step one. Installing an operating system. I expect this machine to run 24 hours a day and want easy remote access to it. My natural choice for an OS was something...

Read More

Including lib and vendor assets in the rails asset pipeline

The rails asset pipeline provides a simple framework to concatenate and minify or compress JavaScript and CSS files. To learn more about the rails asset pipeline I suggest viewing the railscast or reading the rails guide. However both of these resources leave out a minor detail, which took me too long to figure out. Adding //= require_tree . to the main manifest file does not recurse into the lib and vendor assets directories. There are a number of ways to solve this issue but none very elegant. The simplest way to require all assets, is to add the following...

Read More

Setting up a new ruby application

I’ve recently started doing most of my server side web development work in Ruby as opposed to PHP. This has little to do with preference. I accepted a new software developer position and it just so happens they the product is built with Ruby. I happen to really like working with PHP and I have no plans of abandoning the PHP community. So no flame wars please. Having said that I am a ruby noob, and in order to ramp up quickly I’ve decided to build my next personal project using Ruby and the Rails framework. It turns out...

Read More
%d bloggers like this: