From 32accad0b83df313da8ee02c9a9bee8f835bff39 Mon Sep 17 00:00:00 2001 From: Adam Henry Lewenberg <adamhl@stanford.edu> Date: Fri, 16 Jun 2017 09:52:22 -0700 Subject: [PATCH] fix file perms on /root/.ssh/authorized_keys --- manifests/ssh.pp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/manifests/ssh.pp b/manifests/ssh.pp index ae64e1c..18bfddb 100644 --- a/manifests/ssh.pp +++ b/manifests/ssh.pp @@ -117,8 +117,9 @@ class base::ssh( if ($root_authorized_keys) { file { '/root/.ssh/authorized_keys': - ensure => present, + ensure => present, content => $root_authorized_keys, + mode => '0640', } } else { # Make sure public key authentication to root does not work and clean up -- GitLab