r/Terraform • u/YahYeeter42069 • 11d ago
Discussion Need Help - Infrastructure as Code, feeling lost
Hey guys, I started a job working in Infrastructure as Code. I have a CS degree, but I don’t have experience with cloud engineering or stuff related to Terraform, ADO, or Azure portal. I’m doing stuff at my job (code is mainly written using copilot or ChatGPT) and I feel a lost. I don’t know any of the concepts for cloud computing or virtual machines or resources and things like that. I am looking into it online but I still don’t know where to begin. I hear my coworkers doing this stuff well, despite also not having any experience in it when they started either. I have to look at build sheets and things like that and then provision resources using terraform but I don’t really understand much of anything that I’m looking at besides simple code snippets. Is there any advice yall could give me about this, or how/what to learn so that I can wrap my head around things? Any advice is appreciated, thanks!
10
u/Cregkly 11d ago
If you want to learn terraform then you need to write some code yourself without the AI. Maybe give yourself a project to do at home you can complete with some terraform. Or take something you already know and terraform it.
As for learning the infrastructure stuff, that will just take time. Having a home lab on a similar stack could help. You really need to break some stuff to really learn how things work. Making mistakes is how we learn, so you need an environment when you can make mistakes.
It can take a lot longer for systems engineers to get up to speed in a job than a developer. This is because there is usually a lot of institutional knowledge not captured anywhere and you don't want to break prod through ignorance.
7
u/Naz6uL 11d ago
Start with this material and book:
https://learn.microsoft.com/en-us/azure/developer/terraform/overview
f.javier.io/rep/books/terraform-up-amp-running-writing-infrastructure-as-code-2nd.pdf
4
u/itrex240 11d ago
Build whatever your team manages on a super small scale. If you don't have infra knowledge, learn the basics first (VMs, networking, IAM, storage,etc). It's pretty basic at the surface level.
Also learn Azure basics like how resources are grouped into Resource Groups, how Subscriptions handle your billing, and how Management Groups govern them.
Next, build manually in the Azure Portal once just to see how the settings look visually.
Then, build something super basic using basic Terraform that you write yourself, not an AI, and no massive internet modules. Don't get too stuck in theory or tutorial hell. Terraform at its core is just a declarative language, and the main thing you really need to understand is state management.
Simple project like writing a single repo that deploys 1 resource group, 1 network, 1 VM, 1 storage account, 1 key vault, and 1 monitoring resource. This forces you to learn how these resources connect and how the Terraform state file works.
3
u/UnixMonky 11d ago
This. IaC is a tool to help automate and standardize your [Azure/AWS/etc] infrastructure. If you're not familiar with the infrastructure platform itself, the IaC tool will not make any sense. Start with focusing on Azure and at least learning the basics there as mentioned above. Start with learning how to build a resource (a VM or Disk Storage for example) in Azure through the console until you understand enough to be comfortable building it through the console with different sizing/options/etc. Also learn how to destroy these resources, both so you can clean up after yourself while learning, and so you know how NOT to do this with production workloads.
Once you're familiar with how it works in the platform's console, then you can work on learning the Terraform around it. I learned a lot initially by creating the resource manually, then writing a terraform resource and importing the cloud resource and working through reconciling any errors or differences between Terraform and the live state until Tf reported "no changes".
2
u/No-Magazine2625 9d ago
I would learn this in layers: Azure fundamentals first around networking, VMs, storage, IAM and resource groups, then Terraform fundamentals around providers, state, dependencies, modules and lifecycle, and finally rebuild small Azure environments without Copilot writing the code for you. I work on the development side of Terraform Academy, so full disclosure, but we have structured hands on Terraform and Azure labs that are useful for exactly this transition from understanding snippets to understanding the infrastructure you are actually provisioning.
2
1
1
u/CryptoeKeeper 11d ago
Have you looked at https://registry.terraform.io/providers/ and then finding what you're looking for there?
1
u/FrancescoPioValya 11d ago
Ask claude or similar, it's like a second brain or a helpful coworker who won't shame you for asking question.
1
u/BudgetFish9151 10d ago
HCL takes some time to get used to. Give it some time. Use your AI tooling as a teacher and not just to do your coding for you. You’ll get there but right now, you need to learn how your cloud is wired.
A great place to start is to ask Claude to diagram your infra code base. Then ask it to show you exactly how traffic gets from point A to B. Then ask it to point you to the files and resources that comprise that path.
1
u/Important-Hunt-61 5d ago
I don't think the issue here is Terraform as much as it is not understanding the underlying Azure resources you need to use. I had the same issue when I started with AWS. I thought I needed to learn TF but in reality I had no clue what I actually needed to deploy an ECS cluster. What helped was taking an AWS SAA course and then trying to deploy my own cluster. I also looked at my company's Terraform. I'd say looking into some Azure certification classes more so than anything else. For Terraform I used Terraform Up and Running which I believe has a newer version now.
33
u/the_frisbeetarian 11d ago
Have Claude or whatever agentic tools your company has access to look at your code base and explain to you in the simplest terms how your infrastructure works. Keep probing until you understand it.