  The low-energy behavior of near-extremal black holes can be understood from
the near-horizon AdS_2 region. In turn, this region is effectively described by
using Jackiw-Teitelboim gravity coupled to Yang-Mills theory through the
two-dimensional metric and the dilaton field. We show that such a
two-dimensional model of gravity coupled to gauge fields is soluble for an
arbitrary choice of gauge group and gauge couplings. Specifically, we determine
the partition function of the theory on two-dimensional surfaces of arbitrary
genus and with an arbitrary number of boundaries. When solely focusing on the
contribution from surfaces with disk topology, we show that the gravitational
gauge theory is described by the Schwarzian theory coupled to a particle moving
on the gauge group manifold. When considering the contribution from all genera,
we show that the theory is described by a particular double-scaled matrix
integral, where the elements of the matrix are functions that map the gauge
group manifold to complex or real numbers. Finally, we compute the expectation
value of various diffeomorphism invariant observables in the gravitational
gauge theory and find their exact boundary description.
