terraform { required_version = ">= 1.0" required_providers { coder = { source = "coder/coder" version = ">= 0.12" } artifactory = { source = "registry.terraform.io/jfrog/artifactory" version = "~> 8.4.0" } } } variable "jfrog_url" { type = string description = "JFrog instance URL. e.g. https://YYY.jfrog.io" } variable "artifactory_access_token" { type = string description = "The admin-level access token to use for JFrog." } # Configure the Artifactory provider provider "artifactory" { url = join("/", [var.jfrog_url, "artifactory"]) access_token = var.artifactory_access_token } resource "artifactory_scoped_token" "me" { # This is hacky, but on terraform plan the data source gives empty strings, # which fails validation. username = length(data.coder_workspace.me.owner_email) > 0 ? data.coder_workspace.me.owner_email : "plan" } variable "agent_id" { type = string description = "The ID of a Coder agent." } variable "package_managers" { type = map(string) description = <