Wondering if there was any way to call all scripts that are within a folder at all in the provisioner task.
we have our provisioner like so
provisioner “shell” {
environment_vars = [“SUBSCRIPTION_MANAGER_USERNAME={var.subscription_manager_username}","SUBSCRIPTION_MANAGER_PASSWORD={var.subscription_manager_password}”]
execute_command = “echo '{var.ssh_password}' | {{.Vars}} sudo -S -E sh '{{.Path}}'" # This runs the scripts with sudo
scripts = [
"scripts/{var.os_family}/{var.os_flavor}/proxy.sh",
"scripts/{var.os_family}/{var.os_flavor}/upgrade.sh",
"scripts/{var.os_family}/{var.os_flavor}/install.sh",
"scripts/{var.os_family}/${var.os_flavor}/accounts.sh”
]
}
we would like to be able to call all files that are within a folder for the version of the os. What would be the best way to do this.
Ideally id like to add a line to the above like
“scripts/{var.os_family}/{var.os_flavor}/${var.os_version}/*”
but this currently doesnt work.