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

Manage xray meta permission missing #150

Closed
Osazz opened this issue Nov 2, 2024 · 3 comments
Closed

Manage xray meta permission missing #150

Osazz opened this issue Nov 2, 2024 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@Osazz
Copy link

Osazz commented Nov 2, 2024

Describe the bug
In artifactory_permission_target resource [managedXrayMeta](https://registry.terraform.io/providers/jfrog/artifactory/latest/docs/resources/permission_target#managedXrayMeta) permission was one of the one supported and during migration to platform_permission this error

 ╷
 │ Error: Invalid Attribute Value Match
 │ 
 │   with platform_permission.permissions,
 │   on main.tf line 19, in resource "platform_permission" "permissions":
 │   19: resource "platform_permission" "permissions" {
 │ 
 │ Attribute
 │ artifact.actions.groups[Value({"name":"builders","permissions":["ANNOTATE","MANAGE","MANAGEDXRAYMETA","READ","WRITE"]})].permissions[Value("MANAGEDXRAYMETA")]
 │ value must be one of: ["WRITE" "MANAGE" "SCAN" "DELETE" "READ" "ANNOTATE"
 │ "EXECUTE"], got: "MANAGEDXRAYMETA"

From Artifactory Permission UI, I can still select Manage Xray Meta

Image

  • Artifactory Version : "7.99.2"
  • Xray Version: "3.106.7"
  • Terraform version: 1.9.8
resource "platform_permission" "my-permission" {
  name = "my-permission-name"

  artifact = {
    actions = {
      users = [
        {
          name = "my-user"
          permissions = ["READ", "MANAGEDXRAYMETA"]
        }
      ]
    }

    targets = [
      {
        name = "my-docker-local"
        include_patterns = ["**"]
      }
    ]
  }
}

Expected behavior
Able to create permission with managedXrayMeta

@Osazz Osazz added the bug Something isn't working label Nov 2, 2024
@Osazz
Copy link
Author

Osazz commented Nov 4, 2024

In this documentation https://jfrog.com/help/r/jfrog-platform-administration-documentation/select-users-and-assign-permission-actions ManageXrayMeta is still allowed Permission too

@alexhung
Copy link
Member

alexhung commented Nov 4, 2024

@Osazz Thanks for the report! Looks like the resource needs to be updated to include this (and any other new) permissions.

@alexhung
Copy link
Member

alexhung commented Nov 4, 2024

@Osazz My apology. The managedXrayMeta value in the artifactory_permission_target resource is now SCAN in the platform_permission resource. https://registry.terraform.io/providers/jfrog/platform/latest/docs/resources/permission#permissions

@alexhung alexhung closed this as completed Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants