mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-26 20:31:27 -07:00
os.getlogin() returns the user logged in on the controlling terminal. However 'crontab' only looks for the login name of the process' real user id which pwd.getpwuid(os.getuid())[0] does provide. While in most cases there is no difference, the former might fail under certain circumstances (e.g. a lxc container connected by attachment without login), throwing the error 'OSError: [Errno 25] Inappropriate ioctl for device'. |
||
---|---|---|
.. | ||
__init__.py | ||
authorized_key.py | ||
cron.py | ||
group.py | ||
hostname.py | ||
mount.py | ||
ping.py | ||
seboolean.py | ||
selinux.py | ||
service.py | ||
setup.py | ||
sysctl.py | ||
systemd.py | ||
user.py |