473,406 Members | 2,451 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

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

Dec 14 '06 #1
1 1496
mo**********@gmail.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
Dec 14 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: vincent wehren | last post by:
Hi, as a small capabilities demo I coded the piece below to show how to use Python for cgi'ing on localhost and it more or less does the trick :-). However, I when I freeze it with py2exe,...
11
by: tdi | last post by:
Ok, stupid question for the day. I'm reading the interview with Steve Moret and he says: "Once a lot of scripts started going in we knew there was no way we could back out of using Python." I'm...
11
by: ronan_boisard | last post by:
hi all, I'm trying to call ksh script from python. I have a file (toto.env) with a scirpt looking like: -- begin --- #!/bin/ksh # export TOTO_ENV=/home/toto -- end ---
1
by: faxme | last post by:
Hi, I would like to know if it is possible to change code on the fly on a python interpreter. I want to have a python script running a multithread server and be able to connect to this python...
4
by: Ian Giblin | last post by:
I am an experienced C programmer, learning C++ by writinging a mathematical toolkit in the framework of a script interpreter. I am posting here to ask for advice (or references) on the object...
3
by: diffuser78 | last post by:
I am a newbie in Python and want your help in writing python script. I have to remotely shut the windows px from linux box. I run OpenSSH on windows PC. I remotely connect it from Linux box using...
9
by: warpcat | last post by:
I've been scripting in Maya, via mel for years now. Recently learning to Python, love it. Thing that's driving me nuts it the IDE. I'm using PythonWin right now and trying to find something...
4
by: dbee | last post by:
Right. I've got a really, really annoying/difficult/time consuming problem with my development environment. I'm using django to build a web app with paypal integration. My server is hosted...
7
by: Samuel A. Falvo II | last post by:
I have a shell script script.sh that launches a Java process in the background using the &-operator, like so: #!/bin/bash java ... arguments here ... & In my Python code, I want to invoke...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.