diff options
Diffstat (limited to 'mod/ssh-keys-import.rsc')
-rw-r--r-- | mod/ssh-keys-import.rsc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/mod/ssh-keys-import.rsc b/mod/ssh-keys-import.rsc index c7b2788..583e827 100644 --- a/mod/ssh-keys-import.rsc +++ b/mod/ssh-keys-import.rsc @@ -12,7 +12,7 @@ :global SSHKeysImportFile; # import single key passed as string -:set SSHKeysImport do={ +:set SSHKeysImport do={ :do { :local Key [ :tostr $1 ]; :local User [ :tostr $2 ]; @@ -64,10 +64,12 @@ /file/remove "tmpfs/ssh-keys-import"; :return false; } -} +} on-error={ + :global ExitError; $ExitError false $0; +} } # import keys from a file -:set SSHKeysImportFile do={ +:set SSHKeysImportFile do={ :do { :local FileName [ :tostr $1 ]; :local User [ :tostr $2 ]; @@ -106,4 +108,6 @@ $LogPrint warning $0 ("SSH key of type '" . $KeyVal->0 . "' is not supported."); } } -} +} on-error={ + :global ExitError; $ExitError false $0; +} } |