Docker container behind znc.jerryaldrichiii.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

25 lines
563 B

#!/bin/sh
set -e
DATADIR="/srv/znc"
# This pattern is used because ZNC needs to write to this config, but k8s
# mounts secrets as read-only. Sorry normal Docker users...
mkdir -p $DATADIR/configs
cp /bootstrap/configs/znc.conf $DATADIR/configs/znc.conf
if [ -f /bootstrap/tls/znc.key ] && [ -f /bootstrap/tls/znc.crt ]; then
cat /bootstrap/tls/znc.key /bootstrap/tls/znc.crt > /srv/znc/tls/znc.pem
fi
if [ "$ZNC_DEBUG" = "true" ]; then
ZNC_DEBUG="--debug"
else
ZNC_DEBUG=""
fi
/opt/znc/bin/znc \
--foreground \
$ZNC_DEBUG \
--datadir "$DATADIR"