Comment 6 for bug 1604128

Revision history for this message
John George (jog) wrote :

I still get the same failure:
cdoqa@maas-node-1:~$ maas maas sshkeys create key='ssh-rsa PUB_KEY_TEXT'
{"key": ["Invalid SSH public key: 'PosixPath' object has no attribute 'path'"]}

Looking at the installed code it appears one use of keypath.path was changed (i.e. line 139) but a second was not (i.e. line 149):

cdoqa@maas-node-1:~$ egrep -nre str[\(]keypath /usr/lib/python3/dist-packages/provisioningserver
/usr/lib/python3/dist-packages/provisioningserver/utils/sshkey.py:139: ("setsid", "-w", "ssh-keygen", "-e", "-f", str(keypath)),
/usr/lib/python3/dist-packages/provisioningserver/utils/sshkey.py:149: ("setsid", "-w", "ssh-keygen", "-i", "-f", str(keypath.path)),

The following maas packages were installed from xenial-updates:
cdoqa@maas-node-1:~$ dpkg -l | grep maas
ii maas 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all "Metal as a Service" is a physical cloud and IPAM
ii maas-cli 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS client and command-line interface
ii maas-common 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS server common files
ii maas-dhcp 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS DHCP server
ii maas-dns 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS DNS server
ii maas-proxy 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS Caching Proxy
ii maas-rack-controller 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all Rack Controller for MAAS
ii maas-region-api 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all Region controller API service for MAAS
ii maas-region-controller 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all Region Controller for MAAS
ii python3-django-maas 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS server Django web framework (Python 3)
ii python3-maas-client 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS python API client (Python 3)
ii python3-maas-provisioningserver 2.0.0~rc2+bzr5156-0ubuntu1~16.04.2 all MAAS server provisioning libraries (Python 3)