def index():
    # set the config upon first load
    c = ConfigChanger('/ghcc_process/config/config.yaml')
    if not c.config_file_ok():
        return redirect('/config')

    return redirect('/ghaudit?s=0&l=100')
Пример #2
0
def index():
    # set the config upon first load
    c = ConfigChanger('/ghcc_process/config/config.yaml')
    if not c.config_file_ok():
        return redirect('/config')

    return redirect('/ghaudit?s=0&l=100')
def update_config():

    c = ConfigChanger('/ghcc_process/config/config.yaml')
    config = c.get_empty_config()
    config['github']['accesstoken'] = request.form['token']
    config['github']['org_name'] = request.form['orgname']
    config['github']['username'] = request.form['username']
    c.write_config(config)

    # restart ghcc process
    return redirect('/supervisor/restart?proc=ghcc')
Пример #4
0
def update_config():

    c = ConfigChanger('/ghcc_process/config/config.yaml')
    config = c.get_empty_config()
    config['github']['accesstoken'] = request.form['token']
    config['github']['org_name'] = request.form['orgname']
    config['github']['username'] = request.form['username']
    c.write_config(config)

    # restart ghcc process
    return redirect('/supervisor/restart?proc=ghcc')
def edit_config():

    c = ConfigChanger('/ghcc_process/config/config.yaml')
    if not c.config_file_ok():
        config = c.get_empty_config()
        default_config = True
    else:
        config = c.load_config()
        default_config = False

    return render_template('config.html',
                           config=config,
                           default_config=default_config)
Пример #6
0
def edit_config():

    c = ConfigChanger('/ghcc_process/config/config.yaml')
    if not c.config_file_ok():
        config = c.get_empty_config()
        default_config = True
    else:
        config = c.load_config()
        default_config = False

    return render_template('config.html',
                           config=config,
                           default_config=default_config)