If there is a complete chroot environment under /mnt/pxe, you could
configure a new ansible user to always log into a chrooted environment,
using a sshd_config file and these two lines:
Match User new_ansible_user
ChrootDirectory /mnt/pxe
Then use ansible normally under that special user.
But that seems overkill, it would be easier to script the password
change locally with mkpassword and some text manipulation.
On 1/16/19 11:00 AM, eric.b.hymowitz via Ansible Project wrote:
Greetings.
I would like to use the "user" module to change my password, but the
shadow file is not located in /etc/shadow . It's in an alternate
location, specifically, /mnt/pxe/etc/shadow . Is there a way to
accomplish this?
I have a bad feeling that the answer is "only if the underlying passwd
command allows this option," which it doesn't.
I suppose the "lineinfile" module will accomplish this with a little
bit of extra effort, but it would be nice if the standard "user"
module would allow this.
Maybe somebody has a better idea?
Thanks.
--EbH
--
You received this message because you are subscribed to the Google
Groups "Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected]
<mailto:[email protected]>.
To post to this group, send email to [email protected]
<mailto:[email protected]>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/e1b08699-09ab-4ae8-b8dc-7ebe3aef0bdb%40googlegroups.com
<https://groups.google.com/d/msgid/ansible-project/e1b08699-09ab-4ae8-b8dc-7ebe3aef0bdb%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.
--
Hugo F. gonzalez
Senior Consultant
Red Hat LATAM <https://www.redhat.com>
<https://red.ht/sig>
--
You received this message because you are subscribed to the Google Groups "Ansible
Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/1cb5df06-65cc-16a8-fdb6-c4a7365effb5%40redhat.com.
For more options, visit https://groups.google.com/d/optout.