#!/usr/bin/env python3 import html import cgi import os import funct import paramiko from configparser import ConfigParser, ExtendedInterpolation from datetime import datetime from pytz import timezone form = cgi.FieldStorage() serv = form.getvalue('serv') funct.head("Get Running Config") funct.check_config() funct.check_login() path_config = "haproxy-webintarface.config" config = ConfigParser(interpolation=ExtendedInterpolation()) config.read(path_config) ssh_keys = config.get('ssh', 'ssh_keys') ssh_user_name = config.get('ssh', 'ssh_user_name') hap_configs_dir = config.get('configs', 'haproxy_save_configs_dir') haproxy_config_path = config.get('haproxy', 'haproxy_config_path') funct.chooseServer("configshow.py", "Show HAproxy config", "n", onclick="showConfig()") print('