A perfect fluid is in local thermal equilibrium, and the velocity distribution must be the one given by the equilibrium partition function. For a non-interacting gas this is the Maxwell-Juttner distribution. In thermal equilibrium the fluid is completely characterized by thermodynamic variables, for example energy density and pressure, and symmetries fix the form of the stress tensor, $T_{\mu\nu}=(e,p,p,p)$ in the local rest frame. The stress tensor is the only input required by GR.