Ansible Advanced Template Loops Tutorial - Use Loop Vars in Your Templates
In this tutorial video I respond to a question on my Ansible Template Tutorial post on Reddit (http://bit.ly/2RC73T6). @movethrowaway2018 asked:
"How do I replace vars in the template that change with each loop? For example, what if I want to copy a template for a .gitconfig file for multiple users to each user's home directory?"
Great question! In this tutorial I show you my solution to this problem using the Ansible Template Module with a loop.
- 0:46 -- Playbook & Variables (how I set everything up)
- 1:30 -- Ensure Users Exist
- 3:18 -- Create .gitconfig for Each User (using the loop vars in the template)
▶️ TEMPLATE TUTORIAL VIDEO == https://youtu.be/dXl9Yphzbm4
✅ SEE HOW I SET UP ANSIBLE == https://youtu.be/bUac43G20JQ
ℹ️ UPDATED EXAMPLE IN THE TEMPLATE MODULE TUTORIAL ARTICLE == http://bit.ly/2RY2YrH
Thanks for watching and hope it's entertaining/useful for you! Hit me up in the comments if you have any questions or feedback 💪.
Related & Channel
▶️ http://bit.ly/2VWid3D == Playlist of all Ansible videos
⭐️ http://bit.ly/2HavqCu == Subscribe to our YouTube Channel
Our Site & Socials
🌐 http://bit.ly/2shtKwZ == TopTechSkills.com
🐦 http://bit.ly/2RkgZkk == @TopTechSkills on Twitter
🐦 http://bit.ly/2AA19aN == @PercyGrunwald on Twitter
😃 http://bit.ly/2ACQgEW == @TopTechSkills on Facebook
🕹 http://bit.ly/2CWR3ST == @PercyGrunwald on Twitch
Видео Ansible Advanced Template Loops Tutorial - Use Loop Vars in Your Templates канала Percy Grunwald from TopTechSkills
"How do I replace vars in the template that change with each loop? For example, what if I want to copy a template for a .gitconfig file for multiple users to each user's home directory?"
Great question! In this tutorial I show you my solution to this problem using the Ansible Template Module with a loop.
- 0:46 -- Playbook & Variables (how I set everything up)
- 1:30 -- Ensure Users Exist
- 3:18 -- Create .gitconfig for Each User (using the loop vars in the template)
▶️ TEMPLATE TUTORIAL VIDEO == https://youtu.be/dXl9Yphzbm4
✅ SEE HOW I SET UP ANSIBLE == https://youtu.be/bUac43G20JQ
ℹ️ UPDATED EXAMPLE IN THE TEMPLATE MODULE TUTORIAL ARTICLE == http://bit.ly/2RY2YrH
Thanks for watching and hope it's entertaining/useful for you! Hit me up in the comments if you have any questions or feedback 💪.
Related & Channel
▶️ http://bit.ly/2VWid3D == Playlist of all Ansible videos
⭐️ http://bit.ly/2HavqCu == Subscribe to our YouTube Channel
Our Site & Socials
🌐 http://bit.ly/2shtKwZ == TopTechSkills.com
🐦 http://bit.ly/2RkgZkk == @TopTechSkills on Twitter
🐦 http://bit.ly/2AA19aN == @PercyGrunwald on Twitter
😃 http://bit.ly/2ACQgEW == @TopTechSkills on Facebook
🕹 http://bit.ly/2CWR3ST == @PercyGrunwald on Twitch
Видео Ansible Advanced Template Loops Tutorial - Use Loop Vars in Your Templates канала Percy Grunwald from TopTechSkills
Показать
Комментарии отсутствуют
Информация о видео
21 января 2019 г. 14:43:14
00:07:49
Другие видео канала
![Ansible Template Module Tutorial - Complete Beginner's Guide](https://i.ytimg.com/vi/tcP_gxOo7mk/default.jpg)
![Make your Ansible playbooks flexible, maintainable, and scalable](https://i.ytimg.com/vi/kNDL13MJG6Y/default.jpg)
![Looping Over a Dictionary (Map) in Ansible](https://i.ytimg.com/vi/epz4Osa_9_k/default.jpg)
![The Super Mario Effect - Tricking Your Brain into Learning More | Mark Rober | TEDxPenn](https://i.ytimg.com/vi/9vJRopau0g0/default.jpg)
![Ansible Basics Set fact and Register](https://i.ytimg.com/vi/NyHo72gNkzs/default.jpg)
![you need to learn Ansible RIGHT NOW!! (Linux Automation)](https://i.ytimg.com/vi/5hycyr-8EKs/default.jpg)
![Ansible for the Windows Admin by Jeremy Murrah](https://i.ytimg.com/vi/ZI20Y10OKd0/default.jpg)
![Continuous Testing with Molecule, Ansible, and GitHub Actions](https://i.ytimg.com/vi/93urFkaJQ44/default.jpg)
![DevOps| Ansible | file module | ansible loops || real-time examples | ansible tutorial #3](https://i.ytimg.com/vi/wq9dhJ6HeAY/default.jpg)
![The Insane Biology of: The Octopus](https://i.ytimg.com/vi/mFP_AjJeP-M/default.jpg)
![Yaml Tutorial | Learn YAML in 18 mins](https://i.ytimg.com/vi/1uFVr15xDGg/default.jpg)
![Ansible Tutorial Class 7 | Ansible Conditional Variables & Loops | Tech Arkit](https://i.ytimg.com/vi/JYPn5l3ChX0/default.jpg)
![Ansible 101 - Episode 5 - Playbook handlers, environment vars, and variables](https://i.ytimg.com/vi/HU-dkXBCPdU/default.jpg)
![Ansible Module Development in Python by Yves Fauser | Ansible Meetup Munich](https://i.ytimg.com/vi/yAGWU0QC64I/default.jpg)
![What Is Ansible? | How Ansible Works? | Ansible Tutorial For Beginners | DevOps Tools | Simplilearn](https://i.ytimg.com/vi/wgQ3rHFTM4E/default.jpg)
![Ansible Tutorial for Beginners | What is Ansible | Intellipaat](https://i.ytimg.com/vi/YI48bKykx7k/default.jpg)
![Ansible Shell Module Tutorial - Complete Beginner's Guide](https://i.ytimg.com/vi/57gAqKvAKck/default.jpg)
![Ansible Tutorial Part 6 - Ansible Roles Explained with Examples - Create Your Ansible Roles](https://i.ytimg.com/vi/KgoDnSGvJJg/default.jpg)
![Ansible: Creating users from CSV File](https://i.ytimg.com/vi/vd94qsmt5pA/default.jpg)
![Ansible block concetp | Error handling with block rescue concepts](https://i.ytimg.com/vi/BWJXKQsfz3w/default.jpg)