Necrosis of macrophages in the tuberculous granuloma represents a major pathogenic event in tuberculosis. Through a zebrafish forward genetic screen, we identified the mTOR kinase, a master regulator of metabolism, as an early host resistance factor in tuberculosis. We found that mTOR complex 1 protects macrophages from mycobacterium-induced death by enabling infection-induced increases in mitochondrial energy metabolism fueled by glycolysis. These metabolic adaptations are required to prevent mitochondrial damage and death caused specifically by ESAT-6, the principal secreted substrate of the specialized mycobacterial secretion system ESX-1, a key virulence mediator. Thus, the host can effectively counter this early critical mycobacterial virulence mechanism simply by regulating energy metabolism, allowing pathogen-specific immune mechanisms time to develop. Our findings may explain why Mycobacterium tuberculosis, albeit humanity's most lethal pathogen, is successful in only a minority of infected individuals.