Skip to content

Commit

Permalink
Merge pull request #5 from OlivierGuilloux/6.2.38_add_chown_on_shared
Browse files Browse the repository at this point in the history
Add chown / chmod on shared key
  • Loading branch information
OlivierGuilloux authored Feb 6, 2020
2 parents 807ffd8 + 7536b06 commit 588a75e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ ENV FCGI_SOAP_PORT 10000
ENV ADMINADDR [email protected]
ENV REMOTES mail.example.com
ENV DEBIAN_FRONTEND noninteractive
ENV UID_MAILPIPE 1001
ENV GID_MAILPIPE 115

VOLUME /var/log/sympa
VOLUME /etc/sympa/includes
Expand Down
5 changes: 5 additions & 0 deletions etc/service/sympa/run
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ if [ ! -f $PIDFILE ] ; then
mkdir -p /var/lib/sympa/.ssh
echo -n 'no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty,command="/etc/sympa/run.sh" ' > /var/lib/sympa/.ssh/authorized_keys
cat /etc/sympa/shared/id_rsa.pub >> /var/lib/sympa/.ssh/authorized_keys
# Fix permission on ssh key
if [ ${UID_MAILPIPE} != "" ] ; then
chown ${UID_MAILPIPE}:${GID_POSTDROP} /etc/sympa/shared/*
[[ -f /etc/sympa/shared/id_rsa ]] && chmod 600 /etc/sympa/shared/id_rsa
fi
fi

# All output is logged to /var/log/sympa/sympa.log so we redirect stdout and stderr to /dev/null.
Expand Down

0 comments on commit 588a75e

Please sign in to comment.