Skip to content

Commit

Permalink
Merge pull request #6 from EGA-archive/permissions
Browse files Browse the repository at this point in the history
Changing ownership of the injected files
  • Loading branch information
silverdaz committed May 14, 2019
2 parents fffb809 + e67e19a commit 0c4ac4b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion conf/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,15 @@ EOF
if [ "${MQ_VERIFY_PEER}" == 'yes' ] && [ -f "${MQ_CA}" ]; then
# or Yes, Y, 1, True, true...
echo "cacertfile = ${MQ_CA}" >> /etc/ega/mq.conf
chown root:lega "${MQ_CA}"
fi

# For client verification
if [ -f "${MQ_CLIENT_KEY}" ]; then
# Keyfile must be non group nor world writable
chmod 600 ${MQ_CLIENT_KEY}
echo "keyfile = ${MQ_CLIENT_KEY}" >> /etc/ega/mq.conf
chmod 400 "${MQ_CLIENT_KEY}"
chown root:lega "${MQ_CLIENT_KEY}"
fi

if [ -f "${MQ_CLIENT_CERT}" ]; then
Expand All @@ -91,6 +93,7 @@ if [ -f "${MQ_CLIENT_CERT}" ]; then
exit 2
fi
echo "certfile = ${MQ_CLIENT_CERT}" >> /etc/ega/mq.conf
chown root:lega "${MQ_CLIENT_CERT}"
fi


Expand Down

0 comments on commit 0c4ac4b

Please sign in to comment.