Skip to content

Entrypoint escaping was breaking passwords with control characters for sed#8

Open
jonbartels wants to merge 3 commits into
OpenIntegrationEngine:mainfrom
jonbartels:main
Open

Entrypoint escaping was breaking passwords with control characters for sed#8
jonbartels wants to merge 3 commits into
OpenIntegrationEngine:mainfrom
jonbartels:main

Conversation

@jonbartels

@jonbartels jonbartels commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

When passwords are read from env vars, they are handled by the entrypoint to update the application properties file. This handling was not correctly escaping the strings and interactions with sed and control characters for sed were breaking deployments with complex passwords.

This introduces a function to DRY up the code and uses awk instead of sed to avoid control character issues.

I do get warnings awk: warning: escape sequence .' treated as plain .' - Should I fix these?

I also think this might still have issues with #. If a string with # is copied into the properties file without quoting then it may be treated as a comment.

…oint to update the application properties file. This handling was not correctly escaping the strings and interactions with sed and control characters for sed were breaking deployments with complex passwords.

This introduces a function to DRY up the code and uses awk instead of sed to avoid control character issues.

Signed-off-by: Jon Bartels <jonathan.bartels@gmail.com>
Signed-off-by: Jon Bartels <jonathan.bartels@gmail.com>
@jonbartels
jonbartels requested a review from kpalang July 6, 2026 13:57
@kpalang
kpalang requested review from a team, NicoPiel, gibson9583, kayyagari, mgaffigan, ssrowe and tonygermano and removed request for a team July 14, 2026 18:38
Comment thread deploy/entrypoint.sh
set -e

APP_DIR=/opt/engine
APP_DIR=/opt/oie

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: is this supposed to change?

There was no reference to it in the commit messages. Probably should be a separate commit if intentional.

Comment thread deploy/entrypoint.sh
Comment on lines -12 to -18
custom_extension_count=`ls -1 "$APP_DIR"/custom-extensions/*.zip 2>/dev/null | wc -l`
if [ $custom_extension_count != 0 ]; then
echo "Found ${custom_extension_count} custom extensions."
for extension in $(ls -1 "$APP_DIR"/custom-extensions/*.zip); do
unzip -o -q $extension -d "$APP_DIR/extensions"
done
fi

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: was this section intentionally deleted?

It doesn't look like it was moved elsewhere in the file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants