The maneuvering motion simulation of ship in waves needs large space, the simulation based static domain requires a large amount of mesh. On the contrary, the moving domain can reduce the grid amount and improve the simulation speed. This paper studies the establishment of numerical wave tank based moving domain. The wave-generation method of defining inlet boundary conditions is proposed. The level set method is used to solve the free surface. The URANS equation is solved by finite difference method and the projection algorithm. For the wave-generation method of defining inlet boundary conditions, the velocity inlet direction is always fixed because the direction of incident wave is always fixed. Specifically, the yaw should be turned off avoid the disturbance of wave in the y direction. Comparing the simulated wave with the target wave, the numerical results show that the simulated value is coincident with the theoretical value in the moving domain, and there are no obvious signs of dissipation over time. The established moving domain can produce a continuous and qualified wave, which provides a theoretical basis for the study of maneuvering simulation of ship in waves.