It's pretty obvious that you must have a small but sustained gas leak that supplies the closed oven with enough gas that when it ignites it also ignites the supply of gas trapped in the oven. You comment that when the door is left ajar it doesn't happen ... because the gas is leaving the normally confined oven and there's not enough accumulation to "blow out"... in my opinion. Get someone to look at it before any further use, since the gas leak could worsen and really blow the door off... maybe even the front door of your house!