Skip to content

Commit

Permalink
[Airgap] extend yq support
Browse files Browse the repository at this point in the history
The airgap script used to work with the Mike Farah's yq.
Anyway, it was incompatible with the Andrey Kislyuk's yq version (which
is the main python3 version you would get via pip).

Drop the eval arg from yq in the airgap script to make it compatible
with both.

Signed-off-by: Francesco Giudici <[email protected]>
  • Loading branch information
fgiudici committed Jan 31, 2025
1 parent 97db17d commit f59db9e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/elemental-airgap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ get_chart_val() {
local local_fail=${3:-"true"}
local local_condition="[[ \"\$$local_var\" == \"null\" ]]"

eval $local_var='$(helm show values $CHART_NAME_OPERATOR | eval yq eval '.${local_val}' | sed s/\"//g 2>&1)'
eval $local_var='$(helm show values $CHART_NAME_OPERATOR | eval yq '.${local_val}' | sed s/\"//g 2>&1)'
if eval $local_condition; then
if [[ "$local_fail" == "false" ]]; then
log_debug "cannot find $local_val in $CHART_NAME_OPERATOR"
Expand Down

0 comments on commit f59db9e

Please sign in to comment.