summaryrefslogtreecommitdiffstats
path: root/main.py
blob: 66b451f8e9887a27205c6b494b5a619c141d89d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
from src.ogClient import *
from src.ogConfig import *

def main():
	ogconfig = ogConfig()
	if (not ogconfig.parserFile('cfg/ogagent.cfg')):
		print 'Error: Parsing configuration file'
		return 0

	ip = ogconfig.getValueSection('opengnsys', 'ip')
	port = ogconfig.getValueSection('opengnsys', 'port')

	client = ogClient(ip, int(port))
	client.connect()
	client.run()

if __name__ == "__main__":
	main()