r/Python • • Oct 26 '14

Run python scripts from web

Hello everyone,

I have some python scripts that I need people can execute via web, passing some variables to the script with a form.

Any idea? something where to start, I am so lost with this.

For example, a telnet script to enters a router and change some stuff.

What I need is a webpage with a form, where the user can pass some variables to the script, send the form, execute the script described above and show some output.

Its possible using only python? I dont want to use php in the web, I just want to use python.

any help is welcome thank you guys : )

0 Upvotes

10 comments sorted by

View all comments

1

u/swims_with_spacemen Pythonista Oct 27 '14

As of 21:34 Eastern on Sunday, this thread has 5 comments - all answers are valid. 4 of them have been down voted though, with no explanation of why they were down voted. Who ever down voted them- Can you EXPLAIN why you're down voting them?

My post describes infrastructure I'm presently deploying. It works- amazingly. I even said at the top that it was probably too complex for what the user was asking, but since there was no requirements listed by the op I posted it anyway, in case he/she needed something that needed significant throughput.

/u/feuermelder suggested doing it in CGI- a valid alternative, depending on the code that's being executed.

/u/ggtsu_00 even posted CODE.

So, insightful downvoter- care to identify where the problem is here?

0

u/[deleted] Oct 27 '14

i ask same question !! i help here http://www.reddit.com/r/Python/comments/2ka1wy/help_need_to_create_a_script_that_lists/ an onlyu get DOWN VOTES !! why ????? this reddit is HOSTILE i report to admin but no answer