Skip to content

Commit 248f4a7

Browse files
committed
feat: add CHRONOGRAF_AS_ROOT to always run Chronograf as ROOT
1 parent 20abf25 commit 248f4a7

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

chronograf/1.10/alpine/entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ if [ "$1" = 'chronograf' ]; then
99
export BOLT_PATH=${BOLT_PATH:-/var/lib/chronograf/chronograf-v1.db}
1010
fi
1111

12-
if [ "$(id -u)" -ne 0 ]; then
12+
if [ "$(id -u)" -ne 0 ] || { [ ! -z "${CHRONOGRAF_AS_ROOT}" ] && [ "${CHRONOGRAF_AS_ROOT}" != "false" ]; }; then
1313
exec "$@"
1414
else
1515
exec su-exec chronograf "$@"

chronograf/1.10/entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ if [ "$1" = 'chronograf' ]; then
99
export BOLT_PATH=${BOLT_PATH:-/var/lib/chronograf/chronograf-v1.db}
1010
fi
1111

12-
if [ "$(id -u)" -ne 0 ]; then
12+
if [ "$(id -u)" -ne 0 ] || { [ ! -z "${CHRONOGRAF_AS_ROOT}" ] && [ "${CHRONOGRAF_AS_ROOT}" != "false" ]; }; then
1313
exec "$@"
1414
else
1515
exec setpriv --reuid chronograf --regid chronograf --init-groups "$@"

0 commit comments

Comments
 (0)