-
Notifications
You must be signed in to change notification settings - Fork 51
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
v2.0.0 failing to apply with example code from the docs #174
Comments
Thank you for raising this. I could reproduce the bug and it's definitely not a desired behavior. We will look into this and come up with a fix as soon as possible. |
After looking at the snippet more, I see a misconfiguration: vault = data.onepassword_vault.vault.id That ID is a Terraform ID and it does not match the vault ID that you would normally use. The fix for this is using the vault = data.onepassword_vault.vault.uuid I will keep this issue open since I've identified some errors in the examples provided so we will improve them as soon as possible. |
I had the same issue with |
same issue even when using |
Hey @Antse! 👋 I'm sorry to hear that you're encountering this. Unfortunately, I'm unable to reproduce the error when the terraform {
required_providers {
onepassword = {
source = "1Password/onepassword"
version = "~> 2.0"
}
}
}
data "onepassword_vault" "vault" {
name = "demo"
}
resource "onepassword_item" "demo_login" {
vault = data.onepassword_vault.vault.uuid
title = "Demo Terraform Login"
category = "login"
username = "test@example.com"
} This one succeeds when using a service account for example. There is a possibility that what you're encountering is rather the 1Password client failing to create an item. However, there's a bug in the code that doesn't handle it properly, which leads to the crash you're facing. This should be addressed by #178. |
I too am encountering this same issue. I am on an M1 Mac. |
@edif2008 as far I can tell, I think it is a permission issue, give |
The problem in my case was that the 1password connect server did not have write access to the vault. After I replaced the token with one that had write access, I was able to apply the changes. Hopefully this error message can be fixed to show something more helpful. |
Your environment
Terraform Provider Version:
v2.0.0
Connect Server Version:
n/a
CLI Version:
2.24.0
OS:
darwin_arm64
Terraform Version:
v1.8.3
What happened?
What did you expect to happen?
I expected the item to be created in 1password.
Steps to reproduce
Notes & Logs
The text was updated successfully, but these errors were encountered: