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

Non-interactive setup #2619

Closed
gus4rs opened this issue Jul 18, 2023 · 3 comments · Fixed by #2970
Closed

Non-interactive setup #2619

gus4rs opened this issue Jul 18, 2023 · 3 comments · Fixed by #2970
Labels
ux User experience / User Interface related

Comments

@gus4rs
Copy link

gus4rs commented Jul 18, 2023

I am working with ansible playbooks to automatically setup machines with gopass, is there a way to do

gopass setup --crypto=age --storage=fs 

Non-interactively, providing the passphrase as a parameter?

@dominikschulz
Copy link
Member

setup is meant to be interactive while init should be non interactive.

But I haven't verified recently if there is feature parity.

@dominikschulz dominikschulz added the ux User experience / User Interface related label Mar 31, 2024
@AnomalRoil
Copy link
Member

AnomalRoil commented Oct 2, 2024

After #2960
gopass init --crypto=age --storage=fs AGE-SECRET...
does work almost fully non-interactively if providing a native identity and
gopass init --crypto=age --storage=fs AGE-PLUGIN... age1pluginname...
should also work for plugins (we cannot derive the recipient from a plugin secret directly, it needs to be provided).

It still does prompt for password for the identity keyring file tho, which can only be avoided once #2108 will have been implemented, or by having the password being provided as the 3rd argument and then being called through our callback mechanism. I think I could do that easily in my above PR.

A (safer?) alternative would be to support passing the password to the identity file using an env variable, to avoid displaying password in the console history.

@AnomalRoil
Copy link
Member

This now works on master as documented here, using gopass init:
https://github.com/gopasspw/gopass/blob/master/docs/backends/age.md#getting-started

It'll be in the next release @gus4rs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ux User experience / User Interface related
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants