the SSH command "moonlight quit" closes the client and any program launched by moonlight on the server, however, the keyboard or controller input combination does not quit moonlight, or close anything out on the server.
Why... I'm trying to figure out.
See my topic on moonlight embedded github
https://github.com/irtimmer/moonlight-embedded/issues/576