How about an old analogue camcorder plugged into a basic tvcard? Redhat/Fedora has great support for the WinTV style cards. This won't give the best results but will be really cheap and still a lot better than most surveillance system. Regardless of the device used, I'd encode in divx4, with vorbis for the audio - will give very good compression for minimal loss of quality. However, It'll need a fast-ish machine to do it on the fly, test first and if it drops frames try mpeg2 instead.