Manage Windows with Ansible with Kerberos Active Directory authentication

5 Comments



In this technical overview, we will take a look at how to manage Windows with Ansible, including looking at setting up the prerequisites for installing Ansible for Windows management, as well as installing Ansible itself.

We will take a dive into configuring your Ansible environment for Kerberos authentication which allows setting up Ansible to authenticate with your Active Directory domain. This is extremely important in Active Directory environments.

You can clone down the shell script from my Github repository located here:

https://github.com/brandonleegit/ansibleinstall

Also, the commands to run are:

sudo apt-get install gcc python-dev libkrb5-dev -y
sudo apt-get install python3-pip -y
sudo pip3 install –upgrade pip
sudo pip3 install –upgrade virtualenv
pip3 install pywinrm
sudo apt install krb5-user -y
sudo apt-get install python3-kerberos -y
sudo pip3 install ansible

By installing the above prerequisites and Ansible, you can easily manage your Windows servers in just a few steps.

Visit the official Ansible documentation located here:

https://docs.ansible.com/

Take a look at my detailed write-up on how to configure Ansible with Kerberos authentication here:

Configure Ansible Windows Server Kerberos authentication in Ubuntu

Also, check out Virtualizationhowto.com to read more about Ansible and many other topics around cloud, virtualization, networking, automation, security, and much more.

Home



source

5 Comments
    • blank
      Olusegun Orija
      May 11, 2022 07:36 am Reply

      Question please: does the domain account absolutely need to be have been added to an administrator group on the windows vm already? before being able to authenticate with that user?

    • blank
      Niharika raj
      May 11, 2022 07:36 am Reply

      how to find default realm?

    • blank
      Tony G
      May 11, 2022 07:36 am Reply

      Thanks for posting looking at doing a POC at work.

    • blank
      orlando lewis
      May 11, 2022 07:36 am Reply

      Appreciate the knowledge and step by step explanations. Once again Thank you!

    • blank
      Usman Mohammad
      May 11, 2022 07:36 am Reply

      Hi, thanks for the video it helps me a lot !

Leave us a comment