tjukebox: The Only Jukebox You'll Ever Need!

Take an old i-mac and remove the monitor and associated circuit board. The i-mac consists of 3 large circuit boards. One is the motherboard, one is a power supply, and one controlls the monitor. We will only need the motherboard and power suppley.

Make a VGA to mac VGA converter cable. This way you can use any standard VGA monitor and not have to keep the old i-mac monitor sitting around.

Install linux on the i-mac. I used Debian, but you can use others as well. Fedora has a power PC distro, and there's Yellow Dog too. If you removed the monitor, you will need to boot it with the video=ofonly option.

If you plan on disposing of this monitor, find an e-cycling center near you.

Mount the two boards inside the case of your choice. I used an old 1950's standup radio console.

Remove the i-mac speakers and solder in standard stereo speakers. The good thing about i-macs is the have a decent amplifier built in to drive the speakers. Other computers will require an amplifier if you plan on connecting the speakers to the headphone jack.

Connect a larger hard drive to the i-mac. I kept the original hard drive to use as my /, boot, and swap space. I added an 80 GiB hard drive for my multimedia. This will require you to purchase a 2 device IDE cable as well as a power splitter "Y".

Modify /etc/fstab to add the hard drive to the OS

Download and compile the tjukebox server sourcecode.

There are several different ways to get the tjukeboxd program to automatically run on startup. The first is to create a startup script in /etc/init.d/ and one of the /etc/rc directories. A disadvantage is the deamon will run in the background so you will not be able to interact via the keyboard. The second two method are by manipulating the /etc/inittab file. getty can be set to automatically run a program and not prompt for a login. Alternatively, mingetty can be set to autologin a user. You will have to delete the user's password from /etc/shadow to allow the user to be logged in without a passwrd. Editing /etc/passwd and setting the user's shell to the path of tjukeboxd will get the program to run on login. The final method, is to use the same autologin techniqu, but instead of settitng the user's shell to tjukeboxd, place the path in ~/.bagh_profile. this will run the program when the shell is loaded.

You may also need to create an audio group and add this tjukebox user as a member.

As root `chgrp audio /dev/dsp` and `chmod 770 /dev/dsp`. This will allow members of this audio group to use the sound card.

It's helpfull to be able to shut the jukebox down without having to ssh into it or perform the three fingered salute. Here's how I bound the letter key to the shutdown command:
dump your keymap: % dumpkeys > foo
edit the foo file and chnage the key which is bound to the letter "q" to be "Boot"
edit /etc/inittab and change the shutdown command from shutdon -r to shutdon -h. This way it will halt and not reboot.