Fix netconf plugin set_option (#43589)
* To enable set config option with `Netconf` plugin inherit `NetconfBase` class from `AnsiblePlugin` parent class
This commit is contained in:
parent
733e512f35
commit
b0bd1651fa
1 changed files with 4 additions and 4 deletions
|
@ -19,12 +19,12 @@
|
||||||
from __future__ import (absolute_import, division, print_function)
|
from __future__ import (absolute_import, division, print_function)
|
||||||
__metaclass__ = type
|
__metaclass__ = type
|
||||||
|
|
||||||
from abc import ABCMeta, abstractmethod
|
from abc import abstractmethod
|
||||||
from functools import wraps
|
from functools import wraps
|
||||||
|
|
||||||
from ansible.errors import AnsibleError
|
from ansible.errors import AnsibleError
|
||||||
from ansible.module_utils.six import with_metaclass
|
from ansible.plugins import AnsiblePlugin
|
||||||
from ansible.module_utils._text import to_bytes
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from ncclient.operations import RPCError
|
from ncclient.operations import RPCError
|
||||||
|
@ -47,7 +47,7 @@ def ensure_connected(func):
|
||||||
return wrapped
|
return wrapped
|
||||||
|
|
||||||
|
|
||||||
class NetconfBase(with_metaclass(ABCMeta, object)):
|
class NetconfBase(AnsiblePlugin):
|
||||||
"""
|
"""
|
||||||
A base class for implementing Netconf connections
|
A base class for implementing Netconf connections
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue