コード例 #1
0
ファイル: common.py プロジェクト: kkltcjk/1026
def init_conf_file(api=False):
    global CONF_FILE
    if api:
        CONF_FILE = ConfigurationFile(cf.get_sections_api(),
                                      '/tmp/apexlake/apexlake.conf')
    else:
        CONF_FILE = ConfigurationFile(cf.get_sections(),
                                      '/tmp/apexlake/apexlake.conf')
コード例 #2
0
ファイル: common.py プロジェクト: FedericoRessi/yardstick
def init_conf_file(api=False):
    global CONF_FILE
    if api:
        CONF_FILE = ConfigurationFile(cf.get_sections_api(),
                                      '/tmp/apexlake/apexlake.conf')
    else:
        CONF_FILE = ConfigurationFile(cf.get_sections(),
                                      '/tmp/apexlake/apexlake.conf')
コード例 #3
0
ファイル: common.py プロジェクト: kkltcjk/1026
 def validate_configuration_file_section(section, message):
     if section not in cf.get_sections():
         raise ValueError(message)
     return True
コード例 #4
0
def init_conf_file(api=False):
    global CONF_FILE
    if api:
        CONF_FILE = ConfigurationFile(cf.get_sections_api())
    else:
        CONF_FILE = ConfigurationFile(cf.get_sections())
コード例 #5
0
 def validate_configuration_file_section(section, message):
     if section not in cf.get_sections():
         raise ValueError(message)