Swarfega (or the less effective Aldi version) and/or fairy liquid are my usual approach, but I've recently discovered that cheapo own-brand henna shampoo is surprisingly effective on oily gunk.
If it's really bad, a clean solvent or oil can be more effective in the first instance than a detergent.