Deuteronomy 20:11

New American Standard Bible (NASB)
If it [g]agrees to make peace with you and opens to you, then all the people who are found in it shall become your forced labor and shall serve you.

Read Deuteronomy 20:11 in other translations