scottwinkler / terraform-provider-shell

Terraform provider for executing shell commands and saving output to state file
Mozilla Public License 2.0
281 stars 61 forks source link

Not supporting cygwin or mingw-w64 #126

Open trombini77 opened 1 year ago

trombini77 commented 1 year ago

I tested the example in my Windows 10 that has VSCode with MINGW64 and CYGWIN shells and in both I saw it starts a cmd instead of execute the bash shell.

Is possible to fix or set what executable file call when execute them?

aslafy-z commented 4 months ago

I was able to make it execute a bash script by using

provider "shell" {
  interpreter = ["bash", "-c"']
}

Note that "/usr/bin/bash" or "/usr/bin/env", "bash" fails with a not found error.