source: n4d-hostname/trunk/fuentes/example.py @ 135

Last change on this file since 135 was 135, checked in by hectorgh, 4 years ago

adding project files

  • Property svn:executable set to *
File size: 504 bytes
Line 
1#!/usr/bin/python
2import xmlrpclib
3
4server_ip = "zen"
5
6c = xmlrpclib.ServerProxy("https://"+server_ip+":9779")
7user = ("aberlanas","lliurex")
8print c.get_methods("Hostname")
9
10# Get the n4d value of Hostname
11print(c.get_hostname_n4d("","Hostname"))
12# Get the file value of Hostname
13print(c.get_hostname_file("","Hostname"))
14
15# Set the n4d value of Hostname
16#print(c.set_hostname_n4d(user,"Hostname",hostname_new))
17
18# Set the file value of Hostname
19#print(c.set_hostname_file(user,"Hostname",hostname_new))
Note: See TracBrowser for help on using the repository browser.