From efa7f88ff24fb3c5a444ca536b9a6fbb2fa20e17 Mon Sep 17 00:00:00 2001 From: Jason Murray Date: Wed, 8 Mar 2017 11:25:40 +0100 Subject: [PATCH 1/2] Move user file to /etc/sftp/ directory This allows for mounting with ConfigMap or Secrets in Kubernetes --- entrypoint | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/entrypoint b/entrypoint index 861a328..b8b40a6 100755 --- a/entrypoint +++ b/entrypoint @@ -2,8 +2,8 @@ set -e export DEBIAN_FRONTEND=noninteractive -userConfPath="/etc/sftp-users.conf" -userConfFinalPath="/var/run/sftp-users.conf" +userConfPath="/etc/sftp/sftp-users.conf" +userConfFinalPath="/var/run/sftp/sftp-users.conf" function printHelp() { echo "Add users as command arguments, STDIN or mounted in $userConfPath" From af9de40554922682023fc85f197a824b25bd7119 Mon Sep 17 00:00:00 2001 From: Jason Murray Date: Wed, 8 Mar 2017 11:28:26 +0100 Subject: [PATCH 2/2] Update user file path in README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 49d74c3..653aee5 100644 --- a/README.md +++ b/README.md @@ -73,7 +73,7 @@ OpenSSH client, run: `sftp -P 2222 foo@` ``` docker run \ - -v /host/users.conf:/etc/sftp-users.conf:ro \ + -v /host/users.conf:/etc/sftp/sftp-users.conf:ro \ -v mySftpVolume:/home \ -v /host/ssh_host_rsa_key:/etc/ssh/ssh_host_rsa_key \ -v /host/ssh_host_rsa_key.pub:/etc/ssh/ssh_host_rsa_key.pub \