Cuber is now free and open source (Heroku and Capistrano alternative)


After working on this project for several months, I have decided to release it as open source software (Apache-2.0 license):

Thanks to this automation tool we can scale Pushpad (a monolithic Rails app) to thousands of req/s while keeping the cost of infrastructure low (we can save up to 80% compared to what we would pay on a PaaS like Heroku!).

It’s an automation and deployment tool written in Ruby (it’s somewhat similar to Capistrano, but it deploys on Kubernetes, so you don’t need to configure all the servers and it’s more scalable…).

Basically you can deploy a Rails application by defining a Cuberfile (a few lines of Ruby code, like a Capfile for Capistrano) and then typing cuber deploy in your terminal.

It has all the features needed to run an application in production.

Here’s an example Cuberfile that you can use to deploy any Rails app on Kubernetes:

app 'myapp'
repo '.'
buildpacks 'heroku/buildpacks:20'
image 'username/myapp'
dockerconfig 'dockerconfig.json'
kubeconfig 'kubeconfig.yml'
migrate 'rails db:migrate', check: 'rake db:abort_if_pending_migrations'
proc :web, 'bundle exec puma', scale: 3
proc :worker, 'bundle exec sidekiq', scale: 2
cron :mytask, '@daily', 'rake mytask'
env 'RAILS_ENV', 'production'
env 'RAILS_LOG_TO_STDOUT', 'enabled'
env 'RAILS_MASTER_KEY','config/credentials/production.key').strip, secret: true

You can find a lot of information and technical documentation on the project website:

Finally note that Kubernetes is a lot cheaper than Heroku or other PaaS, because it is bare infrastructure. Kubernetes is also offered by most cloud providers, and thus you avoid lock-in with a single service provider.

Please give a star to the project on GitHub if you like it. And if you have questions you can contact me here or on GitHub.


A job well done, Marco & team! Thank you for this tool.

Anything that mitigates costs with running Rails is a welcome boon.

1 Like

Hey @collimarco, please share some info on the architecture you use to achieve high throughput and deliver notifications “in near real-time, without queues”? Is the heavy lifting all done in the Rails monolith, or is it something like Go/ Java/ Elixir/ Node?