AAP cited the New South Wales fire brigade as saying the strike, which hit the pipeline in Glenbrook in the Blue Mountains, also caused a small fire that went out on its own.
AGL is understood to be repairing the pipeline while fire crews monitor the gas.
No injuries were reported.
The storm swept through the mountains yesterday afternoon, bringing heavy rain and hailstones, and left 15,000 homes briefly without power.