A huge fire at a gas pipeline in Malaysia has injured more than 30 people and forced residents to evacuate their homes.