The fire broke out before 6:00 a.m. Monday near the intersection of the Route 30 bypass and Route 202 in Exton.
Several explosions were visible on a Sky6 camera in the area.
No injuries were reported.
The fire affected switching operations on SEPTA's Paoli/Thorndale line.
Service was suspended between Thorndale and Malvern stations, and train 5714 was canceled as utility crews worked on repairs.
Service on the rest of the line was operating with delays of up to 20 minutes.
SEPTA told Action News all service was restored by 9:00 a.m.