Infection leads to infiltration and accumulation of anti-viral CD8+ T cells in the eye, and to the development of tissue resident memory T cells that localize to the eye, including the retina. Here, CD8A is linked to infection.