I managed to crack a little bit by building a cron job to run the bash script that the server deployed, but I'm not sure if this is the best way. I seem to have solved my problems in the short term. For reference, this is the code I used:
import SimpleHTTPServer import SocketServer PORT = 80 Handler = SimpleHTTPServer.SimpleHTTPRequestHandler httpd = SocketServer.TCPServer(("", PORT), Handler) httpd.serve_forever()
Which I concluded in a simple bash script:
#!/bin/bash cd relevant/directory sudo -u ubuntu python simple_server.py
I'm sure it was better to allow use, but after that I just ran
chmod -R 777 bash_script.sh
So that there are no problems with this front.
And then placed in a cronjob to run every minute (the more the merrier, right?)
crontab -e (Just to bring up the relevant file)
Added to this line:
*/1 * * * * path/to/bash_script.sh
And it seems to work. I closed my ssh'd terminal and everything still works and there was nothing left. I will update if something does, but I'm generally happy with this decision (not that I will be in 2 weeks when I learn more about the subject), but it seems very minimal and low, which means that I at least I understand what I just did.
source share