Source: http://hackerspace.lifehacker.com/my-summer-project-install-a-budget-makeshift-home-surv-514126455
Ever wanted to be just as cool as the government? Ever wanted to spy on your own house or watch the newspaper guy throw the paper onto your lawn? Or maybe there's a small chance that you actually have a legitimate need for video surveillance on your property but, like me, are too poor to buy top-of-the-line hardware and software for it. If this sounds like you, then read on!
I, too, had the interest of using a surveillance camera in my house. I accomplished this by re-purposing an old webcam I had sitting around, so it would finally get some use. Now, I use that webcam as my HamCam, to spy on my hamster.
What I did was, I plugged my webcam in to my desktop and installed a program called iSpy. This allowed me to use my webcam as a motion-sensing surveillance camera. Once I installed that, I went through the settings and made a few tweaks to settings. Specifically, I now have it record video upon detecting motion. I also have it run on a schedule, so it turns off around when I go to bed, and turns on again in the morning when there is light enough to see again.
But what about syncing to the cloud, you ask? Fret not; that base is covered too! What I did to achieve this was change the directory my HamCam videos are saved in, so that it's in my Dropbox folder. Now, I can view it on my Dropbox from anywhere I am. Each time motion is detected, I also have it store a snapshot of the photo in my Dropbox for my viewing pleasure.
I wasn't finished just yet, though. The finishing touch to this was having the photos and videos auto-import into my phone's gallery for ease of access. I accomplished this by using an app called DropSync, which auto-downloads or uploads photos to/from your Dropbox. The Pro key costs $4.99, but it's worth it to me. I had them save to a folder in my SD card under DCIM called HamCam. Because they're in my DCIM folder, they can also be auto-backed up to my Google+, and I can spam my friends with them! ...but I don't, because I don't have friends. I have a hamster.
I should mention that this was done on a Windows PC, and my phone is an Android phone. If there is anyone who's had similar experiences on Linux or OSX, with an iPhone or other type of phone, they might post about it below and what they use (hint hint, guys!).
Look at my little Hamlet unknowingly being watched at all times. The NSA would be proud.