MSO4SC / MSOPortal

MSO4SC Web Portal
2 stars 4 forks source link

Canary: fails when no ssh key has been defined #128

Closed Trophime closed 6 years ago

Trophime commented 6 years ago

Using the latest canary fails with previous settings:

2018-06-27T16:30:44.667Z Task started 'hpc_plugin.tasks.prepare_hpc' primary_hpc_wm3rz9 (primary_hpc)
2018-06-27T16:30:46.578Z Task failed 'hpc_plugin.tasks.prepare_hpc' -> not a valid RSA private key file primary_hpc_wm3rz9 (primary_hpc)
SSHException: not a valid RSA private key file
    Traceback (most recent call last):
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/cloudify/dispatch.py", line 641, in main
    payload = handler.handle()
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/cloudify/dispatch.py", line 397, in handle
    result = self.func(*self.args, **kwargs)
  File "/opt/mgmtworker/env/plugins/default_tenant/test-hpc/lib/python2.7/site-packages/hpc_plugin/tasks.py", line 76, in prepare_hpc
    client = SshClient(config['credentials'])
  File "/opt/mgmtworker/env/plugins/default_tenant/test-hpc/lib/python2.7/site-packages/hpc_plugin/ssh.py", line 68, in __init__
    password=private_key_password)
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/paramiko/pkey.py", line 205, in from_private_key
    key = cls(file_obj=file_obj, password=password)
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/paramiko/rsakey.py", line 52, in __init__
    self._from_private_key(file_obj, password)
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/paramiko/rsakey.py", line 178, in _from_private_key
    data = self._read_private_key('RSA', file_obj, password)
  File "/opt/mgmtworker/env/lib/python2.7/site-packages/paramiko/pkey.py", line 265, in _read_private_key
    raise SSHException('not a valid ' + tag + ' private key file')
SSHException: not a valid RSA private key file

guess this is due to a missing SSH key. could this be made optional?

Trophime commented 6 years ago

My bad. It works... but the button turn red at "RUN" even if the job is marked as COMPLETED...

button_keeps_red

emepetres commented 6 years ago

check the execution logs in the cli to see the status of the execution, maybe something else failed after completion?

Trophime commented 6 years ago

the trouble is that this blueprint get stuck in the cli... I will try with an other one then..

Trophime commented 6 years ago

What is actually done after the job has been completed?