We have a customer who has a radio show, which we’ve been recording and posting up to her website for a while. We were using a Windows box with an ancient version of Replay Radio to do the recording daily, and then every few days we used an audio program to compress the files down in size, and then ftp’ed them up, after which we had to manually go into the database to add them into a list. As you can imagine, a bit time consuming.
I finally got around to automating the process using Linux.
Here’s how it works:
- Create a shell script that records the show using mplayer
- Create a shell script to stop the recording
- Create yet another shell script to upload the file using ftp
- Create a php script to check the remote upload folder, and add new files into the database
- Create a shell script to run the remote batch checker using curl
- Set everything up in cron
Took me a bit of time to get it all right, but that’s going to save a whole bunch of time later on.
I’ll give details in another post if anyone is interested.