Repository navigation
MLE-26255: Merge Master back to develop #121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
39b4430
cdcddd2
6ce8fa2
7bb8252
d42ba79
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -6,14 +6,9 @@ MARKLOGIC_ADMIN_PASSWORD="$(< /run/secrets/ml-secrets/password)" | |||||
|
|
||||||
| log () { | ||||||
| local TIMESTAMP=$(date +"%Y-%m-%d %T.%3N") | ||||||
| # Check to make sure pod doesn't terminate if PID value is empty for any reason | ||||||
| # If PID value is empty preStart hook logs are not recorded | ||||||
| if [ -n "$pid" ]; then | ||||||
| echo "${TIMESTAMP} $@" > /proc/$pid/fd/1 | ||||||
| fi | ||||||
| echo "${TIMESTAMP} $@" > /proc/1/fd/1 | ||||||
|
||||||
| echo "${TIMESTAMP} $@" > /proc/1/fd/1 | |
| echo "${TIMESTAMP} $@" > /proc/1/fd/1 2>/dev/null || echo "${TIMESTAMP} $@" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
$messagevariable should be quoted to avoid word-splitting and glob expansion (which can alter log output and, in edge cases, cause unexpected behavior). Update these to useecho \"$message\" ...(orprintf '%s\\n' \"$message\" ...) for stable, predictable logging.