##// END OF EJS Templates
Monitoring test
Monitoring test

File last commit:

r228:229
r259:260
Show More
sendFile.py
39 lines | 944 B | text/x-python | PythonLexer
import optparse, os, sys
pathFile = os.path.dirname(os.path.abspath(__file__))
sys.path.append(os.path.split(pathFile)[0])
from bin.client3 import ABSClient
class sendFile(object):
def __init__(self):
self.output = ""
def execute(self, filename):
if os.path.exists(filename):
#absObj = ABSClient(ipDestino="10.10.10.97")
absObj = ABSClient(ipDestino="10.10.20.27")
self.output = absObj.sendFile(filename)
#pass
else:
print "No file"
def getOutput(self):
return self.output
usage = "::::::::::::\n"
if __name__ == '__main__':
parser = optparse.OptionParser(usage=usage)
parser.add_option("-f", "--filename", dest="filename", type="string", default="", help="Filename")
(options, args) = parser.parse_args()
filename = options.filename
app = sendFile()
app.execute(filename)