Manage Your Merb

Posted by El Draper
on Apr 16, 08

So in getting this blog up and running on a server of mine, I needed a simple way to control and configure the Merb application, preferably with the ability to quickly alter the amount of servers, the logging, or indeed the adapter being used, amongst other things. I also wanted it so that much like Nginx, the Merb application itself would automatically restart if the server got bounced for whatever reason.

Introducing… merb-manage! Hosted over at GitHub, and open source, this is a simple tool that allows you to quickly and easily manage your Merb configurations on a server, and start/stop/restart your Merb applications as per your configuration. It also includes a bash script that can be installed to act as a startup script (such as in /etc/init.d) so that when your server restarts, your Merb applications spring back to life too! You can store the configuration within your application, and simply symlink it to a central configuration directory for merb-manage to go to work on (defaults to /etc/merb-manage), and you can change the adapter, amount of servers, port, user, group, and logging level straight from the configuration! It’ll handle multiple applications and their configurations so you have a one-stop shop for configuring and managing your Merb instances!

It’s fairly simple at the minute and I’m sure there’s some more useful features to be added, so if you have any ideas then simply fork it, add them in, and send me a pull request! Likewise any bugs, issues, either let me know, or even better, fix them and I’ll add them back in to the main tree!

Comments

Leave a response

  1. Michael LeungApr 16 08 @ 01:50PM
    merb-manage is the shit! You should post this on the wiki, dude.
  2. Michael LeungApr 18 08 @ 05:51PM
    Dude, you really should throw this up on RubyForge so people can use the gem install command.
  3. El DraperApr 22 08 @ 10:38PM
    Yeah dude, it's up on RubyForge now, so you can just run "gem install merb-manage" to install it.
  4. DHHApr 23 08 @ 06:52AM
    Michael Leung: Fuck you.
  5. Lindsay HolmwoodJun 02 08 @ 02:07PM
    I've made a Debian package for this at http://holmwood.id.au/~lindsay/packages/merb-manage_0.4_all.deb

    Have you chosen a licence for the tool? It would be nice to specify it in the package. :-)
  6. El DraperJun 02 08 @ 11:23PM
    @lindsay: great work! That'll be really useful for many people I'm sure. And thanks for reminding me, I hadn't stuck a license in there yet. Just had some changes to merge, so I also added in the MIT license for the tool, and a contributors file to keep track of who's contributing to it! Also updated it to version 0.5 and generated a new gem.

    Also, saw the changes you're working on on GitHub, looking good! I've added a comment on one of the commits you made, but the todo list is definitely a good idea!

    Send me a pull request when you're done with your changes and you'd like them merged back into the main codebase, and thanks for the hard work!
  7. Lindsay HolmwoodJun 03 08 @ 03:32AM
    @el, i'll repackage for 0.5 later today and push through my changes.

    I've got a semi-working version for managing individual instances.

    Tests are the next thing. :-)
  8. El DraperJun 17 08 @ 10:00PM
    @lindsay: sorry it took me so long to comment back here, completely forgot that you'd left another comment! Have you re-packaged for 0.5 now? Anything you think would be useful back in the main repository, just send me a pull request on GitHub or drop me an e-mail to let me know it's ready to merge! I appreciate the contributions.

    Oh and yeah tests would be nice, specs would be even better :-)
Comment