Bug #19575

Using effective user leads to Error initializing command: RuntimeError - Unable to upload file on remote system: exit code: 127

Added by Ivan Necas 5 months ago. Updated 5 months ago.

Status:Closed
Priority:Normal
Assigned To:Ivan Necas
Category:-
Target version:Foreman - Team Ivan Iteration 15
Difficulty: Pull request:https://github.com/theforeman/foreman_remote_execution/pull/247
Bugzilla link:1451675
Story points-
Velocity based estimate-
Releaseforeman_remote_execution_core 1.0.4Release relationshipAuto

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1451675

Description of problem:

Error initializing command: RuntimeError - Unable to upload file to /var/tmp/foreman-ssh-cmd-c8506e1b-558d-45a1-a8b5-b4a1c77d7fd3/script on remote system: exit code: 127

Version-Release number of selected component (if applicable):
tfm-rubygem-remote-execution-core 1.0.3

How reproducible:
always

Steps to Reproduce:
1. run job with non-root effective user

Actual results:
The jobs fails with 'Error initializing command: RuntimeError - Unable to upload file to /var/tmp/foreman-ssh-cmd-c8506e1b-558d-45a1-a8b5-b4a1c77d7fd3/script on remote system: exit code: 127' as the result

Expected results:
job doesn't fail with this error

Additional info:
This is a regression introduced in https://bugzilla.redhat.com/show_bug.cgi?id=1389262

Associated revisions

Revision 3fb0706f
Added by Ivan Necas 5 months ago

Fixes #19575 - don't use sudo prefix for script preparation

For the infrastructure files, we use the remote user: the effective
user is for the scope of the actual script

History

#1 Updated by The Foreman Bot 5 months ago

  • Status changed from New to Ready For Testing
  • Assigned To set to Ivan Necas
  • Pull request https://github.com/theforeman/foreman_remote_execution/pull/247 added

#2 Updated by Ivan Necas 5 months ago

  • Subject changed from Using effective user leads to Error initializing command: RuntimeError - Unable to upload file on remote system: exit code: 127 to Using effective user leads to Error initializing command: RuntimeError - Unable to upload file on remote system: exit code: 127
  • Target version set to Team Ivan Iteration 15

#3 Updated by Ivan Necas 5 months ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

#4 Updated by Ivan Necas 5 months ago

  • Release set to foreman_remote_execution_core 1.0.4

Also available in: Atom PDF