Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有人可以向我解释一下,您将如何强制用户在首次使用 Puppet 和 hiera/yaml 登录时更改密码?如果我错了,请纠正我,但我不相信用户资源适合这样的事情......
最快的方法是exec使用类似于以下的命令声明一个新资源:
exec
passwd -e LOGIN
passwd -e使给定 LOGIN 的当前密码过期,因此将要求用户在下次登录时更改它。
passwd -e