Could US Troops Build a Border Wall?

Is it legal to use troops to build the wall? Is is possible to do this as a substitute for Congressional action? And is this a wise use of the military?