run a script and supply commands from a python cgi script

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • moishyyehuda@gmail.com

    #1

    run a script and supply commands from a python cgi script

    Hi

    #1 How do I open a script from another script.
    #2 when I run the script how can I supply commands to the script.
    #3 how do I find the what commands the script needs.

    The thing is like this. I need to set up a module on my server, but i
    cant access the server with a comand line. So I want to run setup.py
    script (I nead to run setup.py to setup up the module) from a python
    cgi script, and supply commands from the script. So if any one can help
    me with this I would appreciate it.

    Moishy

  • Larry Bates

    #2
    Re: run a script and supply commands from a python cgi script

    moishyyehuda@gm ail.com wrote:
    Hi
    >
    #1 How do I open a script from another script.
    Use subprocess or popen
    #2 when I run the script how can I supply commands to the script.
    See documentation on subprocess or popen
    #3 how do I find the what commands the script needs.
    See documentation that comes with the script you wish to run
    >
    The thing is like this. I need to set up a module on my server, but i
    cant access the server with a comand line. So I want to run setup.py
    script (I nead to run setup.py to setup up the module) from a python
    cgi script, and supply commands from the script. So if any one can help
    me with this I would appreciate it.
    >
    Moishy
    >
    This is most likely not going to work. You aren't going to have adequate
    rights for the setup.py script to write to the places that it will need
    to write to. You probably need to switch to an ISP that allows you shell
    access to your server instance or one that will install python modules
    for you on your sever.

    -Larry Bates

    Comment

    Working...