Ask your GP for the form (FP92A) to apply for the Medical Exemption Certificate.
You fill in some bits, your GP has to countersign it and send it off if you're eligible.
Note that this "certificate" (actually a credit card sized piece of plastic) has an expiry date and will need to be renewed every 5 years regardless whether you have a chronic disease with no cure or not.