Complex traits are manifestations of intricate gene interaction networks. Evolution of complex traits revolves around the genetic variation in such networks. Genomics has increased our ability to investigate the complex gene interaction networks, and characterize the extent of genetic variation in these networks. Immunity is a complex trait, for which the ecological drivers and molecular networks are fairly well understood in Drosophila. By characterizing the natural variation in immunity, and mapping how the genome changes during the evolution of immunity in Drosophila, we can integrate our knowledge on the complex genetic architecture of traits and the molecular basis of evolutionary processes.