diff --git a/app/funct.py b/app/funct.py index bf073640..b30d7bf7 100644 --- a/app/funct.py +++ b/app/funct.py @@ -373,7 +373,7 @@ def check_haproxy_config(serv): commands = [ "haproxy -q -c -f %s" % sql.get_setting('haproxy_config_path') ] ssh = ssh_connect(serv) for command in commands: - stdin , stdout, stderr = ssh.exec_command(command) + stdin , stdout, stderr = ssh.exec_command(command, get_pty=True) if not stderr.read(): return True else: @@ -407,7 +407,7 @@ def ssh_command(serv, commands, **kwargs): for command in commands: try: - stdin, stdout, stderr = ssh.exec_command(command) + stdin, stdout, stderr = ssh.exec_command(command,get_pty=True) except: continue @@ -485,4 +485,4 @@ def get_files(dir = get_config_var('configs', 'haproxy_save_configs_dir'), forma return files def get_key(item): - return item[0] \ No newline at end of file + return item[0] diff --git a/app/options.py b/app/options.py index f757cdde..45fd86bd 100644 --- a/app/options.py +++ b/app/options.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python3.5 +#!/usr/bin/env python3 # -*- coding: utf-8 -*-" import html import cgi