Using Ansible 'Pull' Mode to Dynamically Automate Server/Workstation Builds

preview_player
Показать описание
Ansible "Pull" is an often overlooked gem, that makes it even easier to manage your server and workstation builds by combining the power of version control with the flexibility of Ansible. In this video, you'll learn everything you need to know in order to use ansible-pull.

*⏰ TIME CODES*:
1:14 - What is "ansible-pull"?
7:00 - Setting up the Git Repository
14:13 - Running playbooks via ansible-pull

🙌 Support me on Patreon and get early access to new content!

Get $100 toward your own cloud server with Linode!

Wiki article for this video:

🛒 Affiliate store for Linux compatible hardware/accessories (commission earned):

💻 Check out the Tiny Pilot KVM for your Homelab (commission earned):

🐦 Follow me on Twitter!

📖 Check out jay's latest book, Mastering Ubuntu Server 3rd Edition. Available now!

👨 More about me:

💽 How to create a bootable flash drive for installing Linux:

🐧 Which distro do I use?

🔐 How to better secure OpenSSH:

☁️ How to create a cloud Linux server with Linode:
Рекомендации по теме
Комментарии
Автор

Great video, watching this gives me enough confidence to start using ansible-pull across my infrastructure.

A couple of times in the video you allude to some "extra-power" e.g. using pull mode with private repos, setting up a notification on error, but you don't go into further detail. I completely understand you excluding these deeper topics to keep the video streamlined, although it would be extra satisfying if you could provide links to further information on these skipped topics.

Thanks for your hard work on these videos, this is the best working overview of pull mode I've seen so far.

tmthyrd
Автор

I use terraform to create git repositories. It makes it really easy to keep clean repositories. I really like linode, packer, terraform, ansible-pull, and git combination. You can build things out quickly. Great video.

MarkWatsonSMTX
Автор

Video starts at 14:12. The info before is how to create a repository and push a commit to remote.

sandoh
Автор

Thank you very much, Jay, for doing such an amazing work and offering it for free! I believe I have learnt some wonderful things that are intended to be shared with the rest of the world, and individuals like you have made that possible!
I'm hoping to see more fantastic works like this on your YouTube channel in the near future.

jaykayzen
Автор

This is awesome. Ansible pull seems is easy to set up. Now I can roll SSH keys if need be and do mass scale configuration. Thanks for the video.

GrishTech
Автор

No idea how I missed that ansible-pull was a thing. Great video, love the content and the channel

mcdermg
Автор

Great video, I would like to suggest a video on ansible pull with private git repos. I think ppl would look like to see that video as well.

frederickalcantara
Автор

Nice video Jay, didn't even know this function existed, love the cron job playbook

kenmurphy
Автор

this is great stuff jay. so useful. I'm going to set this up immediately. thanks!

kodikodi
Автор

Thank you Soooo much this is going to save me so much time

darylblake
Автор

Great stuff !
This is like a reverse way of IaC via Ansible + Gitlab CI where the Gitlab runners take care of the automated provisioning..
It will be great if you can make a video about it..

ano-xc
Автор

Thank you very much for your video. That was great

vitshirgazin
Автор

Thank you for a great content, Jay! Just a quick question, what would you advise to avoid a theoretical overlapping of two provisions? In your case it would possible if one of the updates lasted more than 10 min.

igorkugaudo
Автор

I'm not sure if I get the "centralize configuration management" thingy here. If you let nodes pull in their Ansible stuff and run it, how do you get a central overview of what's going on then? Then you need to have something easy setup to visualize how these Ansible runs are doing. Otherwise you're flying blind. There are ways to do this, with callback plugins if I recall correctly. But that's not discussed here. So this is not "everything you need to know in order to use ansible-pull".

Also, Ansible has to run the full playbook, which is quite resource intensive. Why not use Salt if you want a setup like this? Which runs an agent and keeps an eye out for what is out of sync and just applies what's needed for that.

UPPERKEES
Автор

Can you do a video on your bootstrap process?

RoborobsComputers
Автор

Cron solution is a little bit "ugly". I would love to see some webhooks in action for such things. Currently im looking for some simple tool for that. I most familiar with Jenkins but its like shooting a flies with a cannon. Rundeck or Stackstorm look big and bulky as well, not to mention AWX. I could write some python script - requests and jsons are easy there. But im not programmer, i prefer to use others (better written) tools. Maybe you could recommend something lightweight?

doman
Автор

Thanks very much, Jay. When is your 4th edition book coming out?

trido
Автор

Please make a video on how to install linux brew via ansible and then manage most packages via brew.

j.h.
Автор

This tool needs a second video: How to manage a set of servers, all with a common set of base packages, but each with its own configuration as well, eg Kubernetes control plane or worker nodes, storage and backup, monitoring, messaging, etc.

Harridu
Автор

I can't seem to figure out how to get it to work with a repo that I have hosted on my private server. I always just get a very long error message

nickhuber