DEV Community

Discussion on: Connect Terraform to Azure DevOps Git Repos over SSH

Collapse
 
michelsylvestre profile image
Michel Sylvestre • Edited

Interesting solution!

If you're curious, I used a different approach with git submodules. I created a terraform repository with common modules/provider configurations/etc... and when I need terraform on a project, I simply add the repo as a submodule in it and reference my modules like:

source = "../../terraform/neededmodule"
Enter fullscreen mode Exit fullscreen mode

The only thing you have to remember is to add a submodules: true in your pipeline job.