Loading...
Loading...
### Terraform Version Terraform v0.9.2 (regression from Terraform 0.8.8 and earlier where this worked) ### Affected Resource(s) File provisioner ### Terraform Configuration Files Tested with multiple providers like vsphere and azurerm and was able to consistently reproduce with both. I put two file provisioners, the first uploading a single file and the second uploading a folder: ``` provisioner "file" { source = "${path.module}/file" destination = "/tmp/file" } provisioner "file" { source = "${path.module}/folder" destination = "/tmp" } ``` ### Debug Output https://gist.github.com/bpoland/278bdcd772712ec750fd874b8e844767 ### Panic Output no panic ### Expected Behavior Both the file and the folder should have been uploaded to the deployed VM without errors. ### Actual Behavior 1 error(s) occurred: * vsphere_virtual_machine.vm: 1 error(s) occurred: * Upload failed: Process exited with status 1 ### Steps to Reproduce 1. Create a folder on disk with a file inside it, and a second file symlinking to the first, e.g. mkdir folder touch folder/fileinfolder ln -s folder/fileinfolder folder/linkinfolder 2. Add a file provisioner to your VM resource, like the above, which should upload the "folder" folder to your VM after creating it 3. terraform apply 4. When terraform tries to upload the folder, it will fail with the above error. ### Important Factoids - I tried using Terraform 0.8.8 against the exact same .tf file and it worked perfectly. Switching to terraform 0.9 or later causes this issue. - After the failure, the symlink file does end up in the target VM but it's a regular file not a symlink and only has some content in it, not the full content of the file that it was linked to. ### References none
Click on a version to see all relevant bugs
Terraform Integration
Learn more about where this data comes from
Bug Scrub Advisor
Streamline upgrades with automated vendor bug scrubs
BugZero Enterprise
Wish you caught this bug sooner? Get proactive today.