The mechanical influence on objects due to their interaction with light has been a central topic in atomic physics for decades. Thus, not surprisingly, one finds that many concepts developed to describe cavity optomechanical systems with solid-state mechanical oscillators have also been developed in a parallel stream of scientific literature pertaining to cold atomic physics. In this chapter, I describe several of these ideas from atomic physics, including optical methods for detecting quantum states of single cold atoms and atomic ensembles, motional effects within single-atom cavity quantum electrodynamics, and collective optical effects such as superradiant Rayleigh scattering and cavity cooling of atomic ensembles. Against this background, I present several experimental realizations of cavity optomechanics in which an atomic ensemble serves as the mechanical element. These are divided between systems driven either by sending light onto the cavity input mirrors ("cavity pumped"), or by sending light onto the atomic ensemble ("side pumped"). The cavity-pumped systems clearly exhibit the key phenomena of cavity optomechanical systems, including cavity-aided position sensing, coherent back action effects such as the optical spring and cavity cooling, and optomechanical bistability; several of these effects have been detected not only for linear but also for quadratic optomechanical coupling. The extreme isolation of the atomic ensemble from mechanical disturbances, and its strong polarizability near the atomic resonance frequency, allow these optomechanical systems to be highly sensitive to quantum radiation pressure fluctuations. I describe several ways in which these fluctuations are observed experimentally. I conclude by considering the side-pumped cavity experiments in terms of cavity optomechanics, complementing recent treatments of these systems in terms of condensed-matter physics concepts such as quantum phase transitions and supersolidity.