diff options
author | James Z.M. Gao <gaozhm@mvad.com> | 2016-05-04 05:14:13 +0800 |
---|---|---|
committer | James Z.M. Gao <gaozhm@mvad.com> | 2016-05-04 05:14:13 +0800 |
commit | 0d532221d14c9e8f0e4315b10a18f3d0dbf94e4e (patch) | |
tree | bf007255f19c5b03efaa4082e74473d3ceb4527b /content/opt | |
parent | b328c9674f4b8fd43dc4fb9360b2624edacd3b83 (diff) | |
download | davmail-0d532221d14c9e8f0e4315b10a18f3d0dbf94e4e.tar.gz davmail-0d532221d14c9e8f0e4315b10a18f3d0dbf94e4e.tar.bz2 davmail-0d532221d14c9e8f0e4315b10a18f3d0dbf94e4e.tar.xz davmail-0d532221d14c9e8f0e4315b10a18f3d0dbf94e4e.zip |
add support for secure ports
Diffstat (limited to 'content/opt')
-rwxr-xr-x | content/opt/davmail/entrypoint.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/content/opt/davmail/entrypoint.sh b/content/opt/davmail/entrypoint.sh index 7b3b518..6555503 100755 --- a/content/opt/davmail/entrypoint.sh +++ b/content/opt/davmail/entrypoint.sh @@ -13,6 +13,15 @@ elif [ -n "$DAVMAIL_URL" ]; then done < /etc/davmail/davmail.properties.template > $CONFIG fi +if [ -n "$DAVMAIL_SSL_PASS" ]; then + if [ ! -r /etc/davmail/davmail.p12 ] || [ ! -s /etc/davmail/davmail.p12 ]; then + echo "ERROR: can't read ssl keystore [/etc/davmail/davmail.p12]!" + return 2 + fi +fi + +if [ -z "$DAVMAIL_SSL_PASS" ] || [ ! -s /etc/davmail/davmail.p12 ] + if [ -r "$CONFIG" ]; then exec /opt/davmail/davmail.sh "$CONFIG" else |