From e59dd46c239368962ba39045bb5bb36bcc3c5f2b Mon Sep 17 00:00:00 2001 From: Alex Waite Date: Tue, 28 Jul 2020 07:36:31 +0200 Subject: [PATCH] fix sftp_umask; store as literal not octal Numbers with leading zeros need to be quoted in Ansible, otherwise they are interpreted as octal. Which the templating happily writes out in... decimal. In this case, sftp_umask 0027 was ending up as 23 in sshd.conf. Signed-off-by: Alex Waite --- README.md | 2 +- defaults/main.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c9255b3..0e5cb2e 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ Warning: This role disables root-login on the target server! Please make sure yo |`ssh_print_motd` | false | false to disable printing of the MOTD| |`ssh_print_last_log` | false | false to disable display of last login information| |`sftp_enabled` | false | true to enable sftp configuration| -|`sftp_umask` | 0027 | Specifies the umask for sftp| +|`sftp_umask` | '0027' | Specifies the umask for sftp| |`sftp_chroot` | true | false to disable chroot for sftp| |`sftp_chroot_dir` | /home/%u | change default sftp chroot location| |`ssh_client_roaming` | false | enable experimental client roaming| diff --git a/defaults/main.yml b/defaults/main.yml index ed7877e..f47c0a6 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -153,7 +153,7 @@ sftp_enabled: false sftp_chroot: true # sftp default umask -sftp_umask: 0027 +sftp_umask: '0027' # change default sftp chroot location sftp_chroot_dir: /home/%u