diff options
author | Garrett Holmstrom <gholms@eucalyptus.com> | 2012-09-24 14:03:19 -0400 |
---|---|---|
committer | Scott Moser <smoser@ubuntu.com> | 2012-09-24 14:03:19 -0400 |
commit | 6c8b9dbae8beb4cb5ebab009b51f01f67114706f (patch) | |
tree | 0e8ae519134f70354f783122478a136155d74628 | |
parent | 94b9647e4df742982cac8a2c2925fb4894281dbf (diff) | |
parent | d852495da6ae8eefee0ff7d2de14c398c0a87a51 (diff) | |
download | vyos-cloud-init-6c8b9dbae8beb4cb5ebab009b51f01f67114706f.tar.gz vyos-cloud-init-6c8b9dbae8beb4cb5ebab009b51f01f67114706f.zip |
fix permissions on /etc/sudoers.d file to be 0440 not 0644
sudo complains about the permissions on the sudoers config file that cloud-init
writes:
[ec2-user@ip-10-166-110-107 ~]$ sudo -s sudo:
/etc/sudoers.d/90-cloud-init-users is mode 0644, should be 0440
This patch makes the file's permissions match sudo's recommendation.
Note: ubuntu's sudo doesn't seem to complain about 644, but 440 is probably
better.
-rw-r--r-- | cloudinit/distros/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cloudinit/distros/__init__.py b/cloudinit/distros/__init__.py index 3e9d934d..612d44af 100644 --- a/cloudinit/distros/__init__.py +++ b/cloudinit/distros/__init__.py @@ -339,7 +339,7 @@ class Distro(object): content += "\n" if not os.path.exists(sudo_file): - util.write_file(sudo_file, content, 0644) + util.write_file(sudo_file, content, 0440) else: try: |