X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=plc-config-tty;h=79f72333e37f6d350288113c31a65880a1a89e67;hb=0c42283cf804fc3ceed07faafedc7a4863b7e475;hp=ddf3fb1d7de9a383d9f086a640ebf1597f78b733;hpb=ebcb2cfd1045049d260dda3c4f17fcdcf6162016;p=myplc.git diff --git a/plc-config-tty b/plc-config-tty index ddf3fb1..79f7233 100755 --- a/plc-config-tty +++ b/plc-config-tty @@ -20,29 +20,32 @@ import getopt from plc_config import PLCConfiguration #################### -release_id = "$Id: plc-config-tty,v 1.6 2006/08/17 16:17:18 thierry Exp $" -release_rev = "$Revision: 1.6 $" +release_id = "$Id: plc-config-tty,v 1.10 2006/12/12 10:14:44 thierry Exp $" +release_rev = "$Revision: 1.10 $" def init_flavour (flavour): global service - global common_variables + global usual_variables if (flavour == "devel"): service="plc-devel" - common_variables=("PLC_DEVEL_FEDORA_URL", + usual_variables=("PLC_DEVEL_FEDORA_URL", "PLC_DEVEL_CVSROOT") config_dir = "/plc/devel/data/etc/planetlab" else: service="plc" - common_variables=("PLC_NAME", - "PLC_ROOT_USER", - "PLC_ROOT_PASSWORD", - "PLC_MAIL_SUPPORT_ADDRESS", - "PLC_DB_HOST", - "PLC_API_HOST", - "PLC_WWW_HOST", - "PLC_BOOT_HOST", - "PLC_NET_DNS1", - "PLC_NET_DNS2") + usual_variables=("PLC_NAME", + "PLC_SLICE_PREFIX", + "PLC_ROOT_USER", + "PLC_ROOT_PASSWORD", + "PLC_MAIL_ENABLED", + "PLC_MAIL_SUPPORT_ADDRESS", + "PLC_DB_HOST", + "PLC_API_HOST", + "PLC_WWW_HOST", + "PLC_BOOT_HOST", + "PLC_NET_DNS1", + "PLC_NET_DNS2", + ) config_dir = "/etc/planetlab" global def_default_config def_default_config= "%s/default_config.xml" % config_dir @@ -365,7 +368,7 @@ def mainloop (cdef, cread, cwrite, default_config, site_config, consolidated_con print ("You might want to type 'r' (restart plc) or 'q' (quit)") elif (command == "u"): try: - for varname in common_variables: + for varname in usual_variables: (category,variable) = cdef.locate_varname(varname) prompt_variable(cdef, cread, cwrite, category, variable, False) except Exception, inst: @@ -434,7 +437,7 @@ def main (): if opt[0] == "-h": usage() if opt[0] == "-v": - print ("This is %s - %s" %(command,release_id)) + print ("This is %s - %s" %(command,release_rev)) sys.exit(1) if opt[0] == "-d": init_flavour("devel")