You mentioned blockage, gas and prolapses which indicates to me that you haven't consulted or referred to see an ostomy dietician to control your diet.
The intestine was not designed to be stuck through the skin, it's a hack basically to keep you alive or to heal something. So lacking the rectal area which expands, the skin constricts the intestine when output is required to exit. So the output needs to be smaller and more liquid like (but not too much liquid volume as that can cause dehydration).
So I'm not a doctor but I have learned that prolapses occur more often with my illeostomy when I failed to follow a proper diet that ensures output is virtually a liquid or extremely soft upon exit like a sludge. If it is more liquid like it just oozes out instead of trying to push larger solid pieces out which may be causing your prolapsing.
Since I saw an ostomy dietician my world has changed for the better and she gave me this very detailed and important guide to follow and I've developed my own diet to insure prolapses and other issues like clogs, diarrhea, gas and pancaking don't occur. I suggest you copy it as it's not available online anywhere.
viewtopic.php?t=27735
An important thing to remember is volume of food intake needs to be controlled as well. Instead of three big meals a day, more like multiple small sandwich size portions over the course of 24 hours.
If you drink alcohol or consume caffeine your very much going to have to quit those until you get a foothold on your diet. You need to learn what does what and you can't do that if caffeine or alcohol is causing you large volumes of liquid output flow. Once you learned to master your diet and intake, master your wafer adhesion etc. then you'll know when you can cheat.
The biggest producers of gas I've found come from drinking carbonated drinks and regular milk. Usually low fat or no fat milk is far less.
Fried foods, salty foods, highly seasoned foods, leafy greens, fruits and vegatables (juice fine) or artificial ingredients all bad. Tough parts of meat, fibrous anything or nuts look out! Clog city.
Then this list is my personal diet list which anything NOT on it is problematic so you can start enjoying less hassle right away.
viewtopic.php?t=27738
Finally this is my very short most agreeable diet for those that are cooking for a disabled person or need a starter diet.
viewtopic.php?t=27755
You will also need clear view ostomy bags to monitor your output to ensure success.
Start out with the diets above and experiment from there as I'm an extreme case, others may be able to tolerate a lot more depending upon the type of ostomy.
Hopefully this will help you avoid or reduce any further issues. If you have any more questions please ask and I'll bring you up to speed.