feat: enhance 1Password lookup functionality with vault ID support and concealment option
Some checks failed
Nix Format Check / check-format (push) Failing after 37s
Some checks failed
Nix Format Check / check-format (push) Failing after 37s
This commit is contained in:
@@ -14,8 +14,11 @@ password: "{{ lookup('onepassword', 'item-name') }}"
|
||||
# Fetch specific field
|
||||
api_key: "{{ lookup('onepassword', 'item-name', field='api_key') }}"
|
||||
|
||||
# Fetch from specific vault
|
||||
database_password: "{{ lookup('onepassword', 'database', field='password', vault='Development') }}"
|
||||
# Fetch from specific vault (using vault ID)
|
||||
database_password: "{{ lookup('onepassword', 'database', field='password', vault='j7nmhqlsjmp2r6umly5t75hzb4') }}"
|
||||
|
||||
# Fetch a field without revealing it (for non-password fields)
|
||||
note: "{{ lookup('onepassword', 'item-name', field='notes', reveal=false) }}"
|
||||
```
|
||||
|
||||
### Prerequisites
|
||||
@@ -24,5 +27,13 @@ database_password: "{{ lookup('onepassword', 'database', field='password', vault
|
||||
2. Sign in to 1Password using `op signin`
|
||||
3. Service account should be properly configured
|
||||
|
||||
### Finding Vault IDs
|
||||
|
||||
To find your vault ID:
|
||||
|
||||
```bash
|
||||
op vault list
|
||||
```
|
||||
|
||||
For more information, see the [1Password CLI documentation](https://developer.1password.com/docs/cli).
|
||||
```
|
||||
|
Reference in New Issue
Block a user