How to really learn DevOps and make it stick.
DevOps requires a lot of interaction with a lot of different systems. Learning about the abstract ideas and terminology of the field won’t be enough to prepare you for a full time job. Even a certification will only help you understand the basics. That’s where real hands on comes in. There is no alternative for this. For this reason I’ve prepared some homework assignments.
The Web API
Part 1
Create an application in any language using any database that returns the following JSON response:
curl http://<url>:<port>/check-in
{“guests”: 1}
curl http://<url>:<port>/check-in
{“guests”: 2}
Each time you call the URL it increments the number of people who have checked in. The reason for this setup is to create an app that requires a database, which will add more non-developer complexity to the setup. The app itself should require very minimum developer skills.
Part 2
Figure out how to manually deploy this to any popular cloud: AWS,Google Cloud, Microsoft Azure. Access your app using an external URL:
curl https://ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com/check-in
This step is going to require a lot of googling for you to finish if you have never done it before. Getting the database talking to the app instance should be especially fun. I will not provide any guides of how to do any of these things. As a future DevOps engineer you will be expected to find guides and documentation on your own. Learning this skill is extremely critical since there is not and never will be any sort of definitive language or platform to govern all of your day to day tasks.
NOTE: Be sure to delete all resources in any cloud environment after you are done using them. They are pay by time. You could end up paying a lot of money if you don’t.
Part 3
Fully automate the above steps.
Developer Automation
Whenever you check in code to your git repo on either github.com or gitlab.com have the changes pushed all the way to your live development environment without any human intervention.
For example lets add a new feature where we return today's date along with the number of guests that have checked in.
curl https://ec2-xxx-xxx-xxx-xxx.compute-1.amazonaws.com/check-in
{“guests”: 1”, “date”:“1/28/2023” }
Make and test the change locally then commit/push to your repo.
Infrastructure Automation
If you set things up manually in Part 2 automate the steps with Terraform. As a bonus for automating it will make it really easy to remove all of the components in your environment.
terraform apploy
terraform destroy
Finishing the Web API
If you can achieve some or even part of the above tasks you should be well on your way to getting that first job in DevOps. You can even use this project as part of your portfolio in your resume. The interesting part of the above task is how it has continued to change over the years. Almost every year there will be a different way to complete the above assignment and not always for the better. It will be up to you to evaluate and document the best cloud practices available to your organization.
Feel free to contact me if you would like further guidance on the above task.
DevOps Gaming??
What if you could experience the thrills of DevOps but in a more fun and contained environment? Well fortunately an entire group of popular games called the automation genre have emerged. The two I recommend are https://www.factorio.com/ and https://www.satisfactorygame.com/.
Why do these game relate to DevOps? The core reason comes down to the struggle between doing things manually and automating them. Here’s a really good article covering some of those lessons learned by playing the game: Things Factorio Taught Me About DevOps
The games also build up your puzzle solving muscles. Additionally, being games, they are really good at giving you the feeling of achievement. I’ve found this feeling of satisfaction very similar to what I feel at work.
Factorio is a 2D factory automation game. It was actually one of the first games to get the whole automation genre going.
Factorio Homework: Fully automate your steam power plant. Here’s a decent guide: https://www.rockpapershotgun.com/factorio-early-game-walkthrough-1-0-how-to-ace-your-first-hour
Satisfactory is the newest game in the genre complete with a full 3D world. Building out a full 3D factory and walking around it can be very satisfying.
Satisfactory Homework: Launch 1 shipment to outer space using the space elevator. The game has a built in tutorial to keep you on that path.