gavinbunney / terraform-provider-bitbucketserver

Terraform provider for Bitbucket Server Management
https://registry.terraform.io/providers/gavinbunney/bitbucketserver/latest
Mozilla Public License 2.0
29 stars 33 forks source link

User Id string support #43

Closed brenwell closed 2 years ago

brenwell commented 2 years ago

Hey there. First up what a great provider!

I have a small issue I would like to solve but I am struggling a little as I am a TF noob. The user_id used in the default reviewers resource is expecting an int however my bitbucket server instance is using the username for the id, which is obviously a string. I would love to help fix this, but I would need a small push in the right direction. I presume it needs to support both and I am not quite sure how to do that. Any help is appreciated. Thanks

{
  "version": 4,
  "terraform_version": "1.1.7",
  "serial": 1,
  "outputs": {},
  "resources": [
    {
      "mode": "managed",
      "type": "bitbucketserver_user",
      "name": "bob",
      "instances": [
        {
          "schema_version": 0,
          "attributes": {
            "display_name": "Bob Builder",
            "id": "bob.builder",
            "initial_password": null,
            "name": "bob.builder",
            "password_length": null
          },
          "sensitive_attributes": [],
        }
      ]
    }
  ]
}
brenwell commented 2 years ago

After some further research, I think this issue is a result of something unusual in our Bitbucket server setup.