Project

General

Profile

Actions

Bug #25764

closed

Ansible Job Templates fails because sudo password is not provided even though it is

Added by Nagoor Shaik over 5 years ago. Updated about 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Description of problem:

Ansible job template shows fatal: [client.example.com]: FAILED! => {"changed": false, "module_stderr": "Shared connection to client.example.com closed.\r\n", "module_stdout": "sudo: a password is required\r\n", "msg": "MODULE FAILURE", "rc": 1}

even though Sudo password is defined in Administer > settings > Remote Execution

This works if we use any other template except ansible (eg - Run command - SSH template)

Version-Release number of selected component (if applicable):
satellite 6.4

Steps to Reproduce:
1. Create user demo on the client system and add it in the sudoers file
2. On satellite in Administer > settings > Remote Execution.

SSH User = demo
Sudo password = password of Demo
Effective User = test

3. Run job from satellite to client using any ansible template.

Actual results:
Fails with error

[client.example.com]: FAILED! => {"changed": false, "module_stderr": "Shared connection to client.example.com closed.\r\n", "module_stdout": "sudo: a password is required\r\n", "msg": "MODULE FAILURE", "rc": 1}

Expected results:
Should successfully execute.

Actions #1

Updated by The Foreman Bot over 5 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman_ansible/pull/231 added
Actions #2

Updated by The Foreman Bot over 5 years ago

  • Assignee set to Adam Ruzicka
  • Pull request https://github.com/theforeman/foreman_ansible/pull/232 added
Actions #3

Updated by Adam Ruzicka over 5 years ago

  • Pull request deleted (https://github.com/theforeman/foreman_ansible/pull/232)
Actions #4

Updated by Marek Hulán about 5 years ago

  • Fixed in Releases foreman-ansible 2.3.1 added
Actions #5

Updated by Nagoor Shaik about 5 years ago

  • Status changed from Ready For Testing to Closed
Actions #6

Updated by Marek Hulán about 5 years ago

  • Fixed in Releases foreman-ansible 2.2.13 added
  • Fixed in Releases deleted (foreman-ansible 2.3.1)
Actions

Also available in: Atom PDF