Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kitchen verify results in sudo error on opensuse-leap-15.1 (after 3.2.0) #568

Closed
myii opened this issue Feb 7, 2020 · 2 comments
Closed

Comments

@myii
Copy link

myii commented Feb 7, 2020

As requested by @zenspider: #548 (comment).


Version:

Any version after 3.2.0, up to and including 3.2.20.

Environment:

Ubuntu Bionic (18.04).

Scenario:

kitchen verify fails with sudo: no tty present and no askpass program specified].

Steps to Reproduce:

Can be reproduced locally or in Travis. Here are the steps for the former:

  1. Clone https://github.com/saltstack-formulas/openssh-formula
  2. Install the gems with respect to the Gemfile
  3. Run kitchen verify default-opensuse-leap-151-2019-2-py3 -- this works as expected (3.2.0)
  4. Install the latest gems for both train and train-core (i.e. 3.2.20)
  5. Run kitchen verify default-opensuse-leap-151-2019-2-py3 -- the error shown below is displayed

Expected Result:

kitchen verify completes.

Actual Result:

-----> Verifying <default-opensuse-leap-151-2019-2-py3>...
>>>>>> ------Exception-------
>>>>>> Class: Kitchen::ActionFailed
>>>>>> Message: 1 actions failed.
>>>>>>     Failed to complete #verify action: [Sudo failed: We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

sudo: no tty present and no askpass program specified] on default-opensuse-leap-151-2019-2-py3
>>>>>> ----------------------
>>>>>> Please see .kitchen/logs/kitchen.log for more details
>>>>>> Also try running `kitchen diagnose --all` for configuration
@tyler-ball
Copy link
Contributor

Verified this is no longer an issue in train 3.2.28 - thanks for the easy repro! This will be released in the latest version of Chef Workstation

@myii
Copy link
Author

myii commented Apr 21, 2020

Verified this is no longer an issue in train 3.2.28 - thanks for the easy repro! This will be released in the latest version of Chef Workstation

@tyler-ball You're welcome and thanks for the fix! I can confirm that it's working now:

myii added a commit to myii/ssf-formula that referenced this issue Apr 21, 2020
* `train` gem fixed so latest version (`3.2.28`) can be used:
  - inspec/train#568
* Idea discussed in the `zookeeper-formula` fix:
  - saltstack-formulas/zookeeper-formula#71
* Idea finalised in the `wg` team discussion:
  - https://github.com/orgs/saltstack-formulas/teams/wg/discussions/27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants