Skip to content

"sudo" support example? #169

@thbar

Description

@thbar

I am using SSHKit to implement a tiny dev-ops checker (similar in spirit to ServerSpec/InSpec, but with more specific needs & also faster due to better parallelisation).

I believe the library does not support sudo explicitly. A sudo call via SSHKit.run will result in an error similar to:

no match of right hand side value: 
[{:ok, [stderr: "sudo", stderr: ": ", 
stderr: "a terminal is required to read the password; either
use the -S option to read from standard input or configure
an askpass helper", stderr: "\n"], 1}]

My current state of research is this:

Did anyone already implement some code around that need? Happy to contribute back some documentation or code if I figure out how to achieve this!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions