Read my latest article: 8 things I look for in a Ruby on Rails app (posted Thu, 06 Jul 2017 17:59:00 GMT)

FeedBurner and lighttpd redirects

Posted by Tue, 22 Aug 2006 20:28:00 GMT

3 comments Latest by Shane Vitarana Mon, 28 Aug 2006 00:14:42 GMT

I haven’t been using feedburner to track counts of subscribers to my feed. I didn’t want to tell everyone to switch their feed URL… so I found this solution for handling this transition through Lighttpd.

First, make sure you are requiring the mod_redirect module.

server.modules              = ( "mod_rewrite", "mod_fastcgi", "mod_compress", "mod_redirect" )

Then add the following… to your lighty configuration.


$HTTP["useragent"] !~ "FeedBurner" {
  url.redirect = (
    "/xml/rss/feed.xml" => "http://feeds.feedburner.com/RobbyOnRails",  
    "/xml/rss20/feed.xml" => "http://feeds.feedburner.com/RobbyOnRails",
    "/xml/atom/feed.xml" => "http://feeds.feedburner.com/RobbyOnRails" 
  )
}

Works like a charm!

Thanks to Damien Tanner for putting me on the right path.

Rails on SCGI and Lighttpd

Posted by Sun, 26 Feb 2006 15:23:00 GMT

5 comments Latest by dgibbons Fri, 03 Mar 2006 18:14:04 GMT

Just recently, we began testing out SCGI with Lighttpd. We were running into weird problems with FCGI and both Apache and Lighttpd… things like fcgi processes that would get spawned and just hang around after the apache or lighttpd processes were killed. We have a few cron scripts that try to play cleanup… but that isn’t a long-term solution.

So, we took the plunge on a few client projects for their demos and I am happy to report that it took maybe 15 minutes to read the documentation and get things going.

I have a new friend and scgi_ctrl is it’s name.

It’s only a matter of time before we work on an rbot plugin so that we can reload our applications via IRC. :-)

Lighttpd, crontab, and server reboots

Posted by Sat, 10 Dec 2005 01:41:00 GMT

I’ll be the first to admit that server reboots do happen. Whether they are for planned hardware upgrades or the unexpected runaway CPU processes…they can cause some problems for your applications.

Recently, we had an unexpected outage on one of our servers and noticed that some of the lighttpd instances were not restarted automatically. I personally went and started up each one manuually and documented who they all were. We wanted to build a nice solution to this… but because every user has their own method of invoking lighttpd and we kind of let you run free with that… the idea to build one init script to meet everyones needs… isn’t currently practical. We want you to have some freedom with that and we can help you along the way. :-)

So… what should you do?

Well, David Gibbons (our new Lead Systems Administrator) has a nice tip on his blog, a cool trick with cron.

He shows you how to use the @reboot option in crontab for scheduling scripts to startup on a reboot.

This is great to use and should work if you are a hosting customer at PLANET ARGON. Expect more little tricks like this in the future as David has many up his sleeve. You might want to subscribe to his brand new Typo blog RSS feed. ;-)

class David < ActiveRecord::Base
  has_many :tricks
end

Have a great weekend!