  We aim to quantify the relation between the dust-to-gas mass ratio (DTG) and
gas-phase metallicity of $z=$2.1-2.5 luminous galaxies and contrast this
high-redshift relation against analogous constraints at z$=$0. We present a
sample of ten star-forming main-sequence galaxies in the redshift range
$2.1<z<2.5$ with rest-optical emission-line information available from the
MOSDEF survey and with ALMA 1.2 millimetre and CO J$=$3-2 follow-up
observations. The galaxies have stellar masses ranging from $10^{10.3}$ to
$10^{10.6}\,\rm{M}_\odot$ and cover a range in star-formation rate from 35 to
145 $\rm{M}_\odot\,\rm{yr}^{-1}$. We calculated the gas-phase oxygen abundance
of these galaxies from rest-optical nebular emission lines (8.4 < $12 +
\log{(\rm{O/H})} < 8.8$, corresponding to 0.5 - 1.25 Z$_\odot$). We estimated
the dust and H$_2$ masses of the galaxies (using a metallicity-dependent
CO-to-H$_2$ conversion factor) from the 1.2~mm and CO J$=$3-2 observations,
respectively, from which we estimated a DTG. We find that the galaxies in this
sample follow the trends already observed between CO line luminosity and
dust-continuum luminosity from $z=0$ to $z=3$, extending such trends to fainter
galaxies at $2.1<z<2.5$ than observed to date. We find no second-order
metallicity dependence in the CO - dust-continuum luminosity relation for the
galaxies presented in this work. The DTGs of main-sequence galaxies at
$2.1<z<2.5$ are consistent with an increase in the DTG with gas-phase
metallicity. The metallicity dependence of the DTG is driven by the metallicity
dependence of the CO-to-H$_2$ conversion factor. Galaxies at z$=$2.1-2.5 are
furthermore consistent with the DTG-metallicity relation found at z$=$0 (i.e.
with no significant evolution), providing relevant constraints for galaxy
formation models.
