Howto Turn Off Auto-Play of CDs,DVDs and iPods in Ubuntu
Go to System--->Preferences--->Removable Drives and Media
Once it Opens You should see the following screen
Now you need to click on Multimedia tab you can just uncheck the box for the disc type you don't want to autoplay
Once you unselect all the options you should see similar to the following screen now you need to click on close
If you are using Feisty by default this is unchecked.