Skip to content

Commit 0c84985

Browse files
authored
Merge pull request #789 from influxdata/BNP_fix_influxdb3-core-enterprise
fix(influxdb): only substitute environment variables when running influxdb3
2 parents 9b7081d + a4ba2a7 commit 0c84985

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

influxdb/3.0-core/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
args=( "${@}" )
5-
for i in "${!args[@]}"; do
6-
args[${i}]="$(echo "${args[${i}]}" | envsubst)"
7-
done
4+
args=("${@}")
5+
6+
if [[ "${1}" == influxdb3 ]] ; then
7+
for i in "${!args[@]}"; do
8+
args[i]="$(envsubst <<<"${args[i]}")"
9+
done
10+
fi
811

912
exec "${args[@]}"

influxdb/3.0-enterprise/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
args=( "${@}" )
5-
for i in "${!args[@]}"; do
6-
args[${i}]="$(echo "${args[${i}]}" | envsubst)"
7-
done
4+
args=("${@}")
5+
6+
if [[ "${1}" == influxdb3 ]] ; then
7+
for i in "${!args[@]}"; do
8+
args[i]="$(envsubst <<<"${args[i]}")"
9+
done
10+
fi
811

912
exec "${args[@]}"

0 commit comments

Comments
 (0)