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

Using the secretsmanager_general data source returns Error: record not found - UID: <UID> #37

Open
g0dfl3sh opened this issue Nov 22, 2024 · 1 comment

Comments

@g0dfl3sh
Copy link

  • Code for reproducing the error
data "secretsmanager_general" "secret_key" {
  path = <PATH_TO_UID>
}
  • Output
Planning failed. Terraform encountered an error while generating this plan.
╷
│ Error: record not found - UID: <PATH_TO_UID>
│ 
│   with data.secretsmanager_general.secret_key,
│   on secrets.tf line 3, in data "secretsmanager_general" "secret_key":
│    3: data "secretsmanager_general" "secret_key" {
│ 
╵
  • Expected Output

Plan should run without errors given the fact that the record with the given UID exists.

I believe the provider documentation in lacking in this regard. Keeper documentation mentions that general is a Legacy format, used for records created before the launch of Record Types. and mentions The record is a legacy (V2) non-typed record as a reason for getting the record not found error.

I am open to submitting a PR in order to fix the docs if you decide that's the right thing to do.

@idimov-keeper
Copy link
Contributor

idimov-keeper commented Nov 22, 2024

I'm assuming you substitute PATH_TO_UID with actual record UID (no path included - since UIDs are unique)
If you have v2 records inside a folder shared to KSM App those records are invisible to KSM and General record type and corresponding data sources/resources will be removed in the next release v1.1.5 (KSM-562 Removed data source type general)

General is the legacy format, used for records created before the launch of Record Types and KSM works only with the new typed records but you can convert your legacy/v2 records to typed/v3 records (using Keeper Commander or web vault in your browser). Both newly created records/v3 and "General/v2" record versions can be converted between types.

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