Skip to content

Commit 9a0e15c

Browse files
authored
Merge pull request #5159 from themarek/dev
improve compatibility with FreeBSD
2 parents f7f8ea9 + e0c63d5 commit 9a0e15c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

deploy/vault.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,10 @@ vault_deploy() {
7070

7171
# JSON does not allow multiline strings.
7272
# So replacing new-lines with "\n" here
73-
_ckey=$(sed -z 's/\n/\\n/g' <"$2")
74-
_ccert=$(sed -z 's/\n/\\n/g' <"$3")
75-
_cca=$(sed -z 's/\n/\\n/g' <"$4")
76-
_cfullchain=$(sed -z 's/\n/\\n/g' <"$5")
73+
_ckey=$(sed -e ':a' -e N -e '$ ! ba' -e 's/\n/\\n/g' <"$2")
74+
_ccert=$(sed -e ':a' -e N -e '$ ! ba' -e 's/\n/\\n/g' <"$3")
75+
_cca=$(sed -e ':a' -e N -e '$ ! ba' -e 's/\n/\\n/g' <"$4")
76+
_cfullchain=$(sed -e ':a' -e N -e '$ ! ba' -e 's/\n/\\n/g' <"$5")
7777

7878
export _H1="X-Vault-Token: $VAULT_TOKEN"
7979

0 commit comments

Comments
 (0)