Tuesday, 23 June 2020

Lesson Learn -- OS profile in Terraform

Hello All,

Throughout my journey on learning terraform and start deploying resources mainly Virtual Machine, i just realize that i miss out one of most important parameter in OS Profile config which did not specify the code as below.


         os_profile_windows_config{
             enable_automatic_upgrades = false # For windows Update
             provision_vm_agent = true  #install and enable Azure VM agent 
            }


The VM will be still be deploy as normal but you will notice the vm name would not appear .

Sample As below 

1 VM01 was deploy without the specify the code as mention on top 


2. VM02 was deploy with the code 




 after certain research done and end up i found the solution in the github but one thing to clarify, even if you add the code into VM01 code in Terraform it wont be able to change it anymore. There a few way to solve it either via redeploy it , PowerShell and azure resourcer explore. 

Hope this will help for those who is still beginner in terraform like me, Cheer 😊😊

Kubecost on AKS Part 02