Skip to content
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

Don't require to shell-escape conf_overrides #20

Merged
merged 1 commit into from
Mar 12, 2024

Conversation

mandre
Copy link
Contributor

@mandre mandre commented Mar 11, 2024

Use heredoc syntax to append the value of conf_overrides to the local.conf file. Compared to the previous solution using echo, this removes the need to shell escape your value.

Also remove the useless test, since the default value for inputs.conf_overrides is an empty string which results in a noop.

Fixes #19.

Use heredoc syntax to append the value of `conf_overrides` to the
`local.conf` file. Compared to the previous solution using `echo`, this
removes the need to shell escape your value.

Also remove the useless test, since the default value for
`inputs.conf_overrides` is an empty string which results in a noop.

Fixes EmilienM#19.
@pierreprinetti
Copy link

LGTM 👍
The variable is replaced before Bash is even executed; this means that quotes in the variable are pasted as-is, and could terminate the quotes that start the argument to echo. Good catch @mandre

@EmilienM EmilienM merged commit 5fa6a4e into EmilienM:main Mar 12, 2024
4 of 8 checks passed
@EmilienM
Copy link
Owner

Merged from the beach

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.

unescaped conf_overrides can cause it to fail
3 participants