The wave equation in Minkowski space can be given as $-\frac{\partial^2\phi}{\partial t^2}+\frac{\partial^2\phi}{\partial x^2}+\frac{\partial^2\phi}{\partial y^2}+\frac{\partial^2\phi}{\partial z^2}= 0$.
In a curved spacetime this can be re-written in the form $g^{\mu \nu}\nabla_{\mu}\nabla_{\nu}\phi = 0$, where $\nabla_{\mu}$ and $\nabla_{\nu}$ are covariant derivatives and $g^{\mu\nu}$ is a metric in $\it{M}^4$.
How can I determine the form of this equation in the spacetime with line element $ds^2 = -dt^2 + a(t)(dx^2 + dy^2 + dz^2)$?