tailscale / terraform-provider-tailscale

Terraform provider for Tailscale
https://registry.terraform.io/providers/tailscale/tailscale
MIT License
264 stars 47 forks source link

FR: Support setting custom device posture attributes​ #393

Open timvy opened 3 months ago

timvy commented 3 months ago

Is your feature request related to a problem? Please describe. The provide currently does not support setting a custom posture attribute for a device. This is currently only possible via the API https://tailscale.com/api#tag/devices/POST/device/{deviceId}/attributes/{attributeKey}

Describe the solution you'd like This could be implemented like this:

data "tailscale_device" "sample_device" {
  name = "device.example.com"
}

resource "tailscale_posture_attribute" "sample_posture_attribute" {
  device_id = data.tailscale_device.sample_device.id
  attributes {
    "custom:location"  = "bedroom"
    "custom:cloud" = "aws"
}

Additional context