Skip to content

Commit

Permalink
Fix regression in apply-config-from-env.py (apache#9097)
Browse files Browse the repository at this point in the history
### Motivation

Fix the regression that introduced in apache#8709 

In apache#8709, if values contain spaces, the value will be wrapped as "value", this will introduce break changes while users already have some configs with the value that contains spaces, so this PR is reverting this change.

If users want to ensure some values are processed as a group, they should use `export key=\"value\"` instead of implicitly adding `""` when encountering spaces
  • Loading branch information
codelipenghui authored Jan 4, 2021
1 parent 21a3a3b commit 4ad499d
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions docker/pulsar/scripts/apply-config-from-env.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,6 @@
for k in sorted(os.environ.keys()):
v = os.environ[k].strip()

# Quote the value if it contains a space.
if v.find(" ") >= 0:
v = '\"%s\"' % v

# Hide the value in logs if is password.
if "password" in k:
displayValue = "********"
Expand All @@ -81,10 +77,6 @@
if not k.startswith(PF_ENV_PREFIX):
continue

# Quote the value if it contains a space.
if v.find(" ") >= 0:
v = '\"%s\"' % v

# Hide the value in logs if is password.
if "password" in k:
displayValue = "********"
Expand Down

0 comments on commit 4ad499d

Please sign in to comment.