Script reboot remote linux

how do I insert a script that enables a button on the home to restart a remote linux server?