Member-only story

User password expiration — Ansible module user

How to ser the user password expiration applying the Linux aging policy system.

Luca Berton
5 min readNov 9, 2021

How to set user password expiration time on Linux with Ansible?

I’m going to show you a live demo with some simple Ansible code.

I’m Luca Berton and welcome to today’s episode of Ansible Pilot.

Ansible user password expiration

  • ansible.builtin.user
  • Manage user accounts

Today we’re talking about the Ansible module user.

The full name is ansible.builtin.user, which means that is part of the collection of modules “builtin” with ansible and shipped with it.

It’s a module pretty stable and out for years, it manages user accounts and supports a huge variety of Linux distributions.

For Windows, use the `ansible.windows.win_user` module instead.

Linux password aging policy

--

--

Luca Berton
Luca Berton

Written by Luca Berton

I help creative Automation DevOps, Cloud Engineer, System Administrator, and IT Professional to succeed with Ansible Technology to automate more things everyday

No responses yet