egawasaki chiba
fabコマンドで「AttributeError: ‘module’ object has no attribute ‘GSSException’」のエラーが出力されて少し手間取ったのでその解決策をシェアしようと思います。
Fixes this issue.
Attempting to use fab when python(2.7)-gssapi fails with an AttributeError:
# fab -v Python 2.7.5 (default, Oct 20 2018, 01:38:06) (most recent call last): File "", line 1, in File "/usr/lib/python2.7/site-packages/paramiko/init.py", line 31, in from paramiko.transport import SecurityOptions, Transport File "/usr/lib/python2.7/site-packages/paramiko/transport.py", line 38, in from paramiko.auth_handler import AuthHandler File "/usr/lib/python2.7/site-packages/paramiko/auth_handler.py", line 48, in from paramiko.ssh_gss import GSSAuth, GSS_EXCEPTIONS File "/usr/lib/python2.7/site-packages/paramiko/ssh_gss.py", line 54, in GSS_EXCEPTIONS = (gssapi.GSSException,) AttributeError: 'module' object has no attribute 'GSSException'
solution 解決策
vi /usr/lib/python2.7/site-packages/paramiko/ssh_gss.py
53.55行を編集して解決しました。
53:import gssapi.error
55:GSS_EXCEPTIONS = (gssapi.error.GSSException,)
52 try: 53 import gssapi.error 54 55 GSS_EXCEPTIONS = (gssapi.error.GSSException,) 56 except (ImportError, OSError): 57 try: 58 import pywintypes 59 import sspicon 60 import sspi
github Jenkins fab pip command
コメント