Main Forum Index

Forum Home

Post Reply

Email Forum Admins

Log In

Search Forums

Read Messages

Send a Message

Edit Your Settings

Forum Rules


I actually kind of like ansible......
By:  pudds (Canadian; 17539)
Posted on: 10-17-2020 16:00.
Client: Mozilla/5.0 (Linux; Android 11; Pixel 2 XL) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.99 Mobile Safari/537.36
IP: Logged 
Message views: 10 (Score: 0)  

I've only glanced at puppet so I can't compare, but I like how ansible uses desired state, rather than just a bunch of scripted commands.

For one of our projects, I created a playbook to deploy to a server, which basically just uninstalls the app, installs the latest, then either installs a service or starts it.

I didn't have to write a script to perform differently if the service already exists, I just created a service task that says this service should be running at the end, and ansible is smart enough to either start or install the service.

Once I got my head wrapped around the concept, it really clicked for me. I can use the same script to put an existing server into a desired state, or to install everything from scratch on a totally clean server, just by adding another server to the inventory.