Bug 218724 - sysutils/ansible: 2.3.0 does not pass su password correcly
Summary: sysutils/ansible: 2.3.0 does not pass su password correcly
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Nikolai Lifanov
Depends on:
Reported: 2017-04-18 09:45 UTC by Guillaume Bibaut
Modified: 2017-06-22 18:53 UTC (History)
1 user (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Guillaume Bibaut 2017-04-18 09:45:57 UTC
- Host: FreeBSD 11.0
- Ansible: 2.3.0

I'm using ansible since version 2.1, and with all the 'become' changes I finally had found a way to install a few things with 'su' method. I'm using the 'su' method because I need to install just a few packages and files on freshly installed servers.

With version 2.2.1, the su password was well sent to each server, but with 2.3.0, nothing happens and the 'su' command on the remote server hangs forever.

my site.yml:
- hosts: all
  become: yes
  become_method: su
  become_user: root
  gather_facts: False
    ansible_python_interpreter: "/usr/local/bin/python"

  - name: Install python with raw as ansible relies on it for most commands except raw
    raw: pkg install -fy python

my ansible.cfg:
transport = paramiko
become_ask_pass = True
host_key_checking = False

ssh_args=-o ForwardAgent=yes

the anible command I'm using:
ansible-playbook -i ./hosts -u remoteuser -k -K site.yml

Works well with 2.2.1.
Does not work with 2.3.0.
Comment 1 Steve Wills freebsd_committer 2017-04-18 12:12:03 UTC
(In reply to Guillaume Bibaut from comment #0)
You should file this bug upstream at:


though it looks like:


is similar if not exactly the same.

(Also fixing title and assigning to maintainer while here.)
Comment 2 Guillaume Bibaut 2017-04-18 13:39:01 UTC
(In reply to Steve Wills from comment #1)
Added a new issue upstream:
Comment 3 commit-hook freebsd_committer 2017-04-18 17:52:04 UTC
A commit references this bug:

Author: lifanov
Date: Tue Apr 18 17:51:44 UTC 2017
New revision: 438787
URL: https://svnweb.freebsd.org/changeset/ports/438787

  sysutils/ansible: fix prompt for become-method=su

  PR:		218724
  Reported by:	Guillaume Bibaut <yom@iaelu.net>

Comment 4 Nikolai Lifanov freebsd_committer 2017-04-18 17:53:05 UTC
Fixed, thank you!
Comment 5 commit-hook freebsd_committer 2017-06-22 18:53:54 UTC
A commit references this bug:

Author: lifanov
Date: Thu Jun 22 18:53:31 UTC 2017
New revision: 444127
URL: https://svnweb.freebsd.org/changeset/ports/444127

  MFH: r438364 r438419 r438787 r441093 r442458

  update sysutils/ansible to

  This is a major release!


  o stop "fixing" default interpreter of /usr/bin/python
  o remove NETADDR option and depend on py-netaddr unconditionally

  Differential Revision:	https://reviews.freebsd.org/D10165

  sysutils/ansible1: fix packaging

  Also, bump expiration date again since I touched it.
  I plan to keep it around until sysutils/py-ploy_ansible is migrated.

  sysutils/ansible: fix prompt for become-method=su

  PR:		218724
  Reported by:	Guillaume Bibaut <yom@iaelu.net>

  sysutils/ansible: add dependency on py-jmespath

  o add missing dependency on py-jmespath required by built-in jsonquery
  o sort dependency list

  PR:		219359
  Submitted by:	Dave Cottlehuber <dch@skunkwerks.at>

  update sysutils/ansible to

  Relnotes:	https://github.com/ansible/ansible/blob/v2.3.1.0-1/CHANGELOG.md
  Security:	15a04b9f-47cb-11e7-a853-001fbc0f280f

  Approved by:	ports-secteam (feld)

_U  branches/2017Q2/