I trying to deploy some packages in windows OS through terraform 15.1 version. And I am able to deploy successful deployment when I use this in provisioners
Connection {
type = winrm
user = administrator
password = ########
timeout = "3m"
port = 5986
https = true
insecure = true
host = self.access_ip_v4
}
but my goal to achieve is that the connection should be encrypted from where we are running terraform command to remote windows machine
So, I want to use some thing like
connection {
type = winrm
user = administrator
password = ########
timeout = "3m"
port = 5986
https = true
**insecure = false**
**cacert = <from where I can this file or value >**
host = self.access_ip_v4
}
Remember that through terraform "user_data" I am using one Powershell script which create self certificate, open wirnrm https firewall port for winrm at the time of window provision.
I have not complete idea how to get this cacert for window. Please can someone help me in this.