Welcome to the PufferPanel community forums! If you need help please register an account and post in the Support category.

How do I use Remote Requests



  • Hey I'm sorry if theres a Topic already made on this Topic but I am new to all this stuff and was wondering how to make a Remote Request thing to restart my server when I use the command /restart like how do I use curl to make the start.sh script to restart the server. I have looked all over the internet searching for like 3 days now but I have not found anything helpfull yet.



  • You'll need to go to your server, go to Remote Requests and then create a new OAuth Client

    Make note of the secret key that you'll see at the top, as well as the server id you'll see on the Remote Requests page.

    Unfortunately the API doesn't seem to support a restart command, but I'll see if I can make a PR to implement one. In the meantime the following script is rather hacky but will stop and then restart the server.

    https://gist.github.com/lukeberry99/70fc95a27bcc0d371ccceee1d754695f

    You'll need to edit the script and add your IP address/domain (include http://), your server id from the Remote Requests page, your secret, and your client id.

    You'll also a variable called DELAY - this is how long the script will wait after sending the stop command before issuing the start command, 10 seconds works for on a relatively small PaperMC server but may need tinkering.

    Let me know if this works for you, or if you need any help.


Log in to reply
 

4
Online

994
Users

943
Topics

3.8k
Posts