The moon offers both problems we need to solve like an exceedingly harsh environment and the shelter we need as we solve the problems.
I know. It drives me absolutely nuts.
The moon has enough of a precious resource (gravity) to provide ultraharsh environmental research on survival in said environment.