mirror of
https://github.com/librenms/docker.git
synced 2026-01-23 02:14:48 +00:00
Provide ability to override Memcached and RRD ports
This commit is contained in:
parent
0dd57a170c
commit
6e032f3a81
1 changed files with 6 additions and 2 deletions
|
|
@ -20,6 +20,10 @@ DB_NAME=${DB_NAME:-"librenms"}
|
|||
DB_USER=${DB_USER:-"librenms"}
|
||||
DB_PASSWORD=${DB_PASSWORD:-"asupersecretpassword"}
|
||||
|
||||
MEMCACHED_PORT=${MEMCACHED_PORT:-"11211"}
|
||||
|
||||
RRDCACHED_PORT=${RRDCACHED_PORT:-"42217"}
|
||||
|
||||
# Timezone
|
||||
echo "Setting timezone to ${TZ}..."
|
||||
ln -snf /usr/share/zoneinfo/${TZ} /etc/localtime
|
||||
|
|
@ -112,7 +116,7 @@ if [ ! -z "${MEMCACHED_HOST}" ]; then
|
|||
<?php
|
||||
\$config['memcached']['enable'] = true;
|
||||
\$config['memcached']['host'] = '$MEMCACHED_HOST';
|
||||
\$config['memcached']['port'] = 11211;
|
||||
\$config['memcached']['port'] = $MEMCACHED_PORT;
|
||||
EOL
|
||||
fi
|
||||
|
||||
|
|
@ -120,7 +124,7 @@ fi
|
|||
if [ ! -z "${RRDCACHED_HOST}" ]; then
|
||||
cat > ${LIBRENMS_PATH}/config.d/rrdcached.php <<EOL
|
||||
<?php
|
||||
\$config['rrdcached'] = "${RRDCACHED_HOST}:42217";
|
||||
\$config['rrdcached'] = "${RRDCACHED_HOST}:${RRDCACHED_PORT}";
|
||||
EOL
|
||||
fi
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue