mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Set paramiko's logging level
Excplicity set paramiko's logging level to WARNING. By default it inherits ansible's DEBUG logging level (set in callbacks.py) and fills the log file with useless debug messages. Obviously it only applies if log_path is set in ansible.cfg
This commit is contained in:
parent
14aa54172c
commit
e96bc981ce
1 changed files with 2 additions and 0 deletions
|
@ -20,6 +20,7 @@ import os
|
|||
import pipes
|
||||
import socket
|
||||
import random
|
||||
import logging
|
||||
from ansible.callbacks import vvv
|
||||
from ansible import errors
|
||||
from ansible import utils
|
||||
|
@ -31,6 +32,7 @@ with warnings.catch_warnings():
|
|||
try:
|
||||
import paramiko
|
||||
HAVE_PARAMIKO=True
|
||||
logging.getLogger("paramiko").setLevel(logging.WARNING)
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
|
|
Loading…
Reference in a new issue