Skip to content

Commit

Permalink
DO NOT MERGE
Browse files Browse the repository at this point in the history
Signed-off-by: Nikolay Mitrofanov <[email protected]>
  • Loading branch information
name212 committed Sep 20, 2024
1 parent 8e64419 commit 5d971a6
Showing 1 changed file with 21 additions and 5 deletions.
26 changes: 21 additions & 5 deletions testing/cloud_layouts/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -461,14 +461,24 @@ export PATH="/opt/deckhouse/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bi
export LANG=C
set -Eeuo pipefail
d8-curl -sLfo /usr/bin/yq https://github.com/mikefarah/yq/releases/latest/download/yq_linux_386
>&2 echo "Download yq..."
chmod +x /usr/bin/yq
d8-curl -sLfo /opt/deckhouse/bin/yq https://github.com/mikefarah/yq/releases/download/v4.44.3/yq_linux_amd64
command -v yq >/dev/null 2>&1 || exit 1
>&2 echo "chmod yq..."
chmod +x /opt/deckhouse/bin/yq
>&2 echo "Create release file ..."
echo "$release" > /tmp/releaseFile.yaml
>&2 echo "Release file ..."
cat /tmp/releaseFile.yaml
>&2 echo "Apply module config ..."
echo 'apiVersion: deckhouse.io/v1alpha1
kind: ModuleConfig
metadata:
Expand All @@ -479,6 +489,8 @@ spec:
update:
mode: Auto' | kubectl apply -f -
>&2 echo "Apply deckhousereleases ..."
echo 'apiVersion: deckhouse.io/v1alpha1
approved: false
kind: DeckhouseRelease
Expand All @@ -488,11 +500,15 @@ metadata:
name: v1.96.3
spec:
version: v1.96.3
requirements:
' | yq '. | load("/tmp/releaseFile.yaml") as \$d1 | .spec.requirements=\$d1.requirements' | kubectl apply -f -
requirements: {}
' | /opt/deckhouse/bin/yq '. | load("/tmp/releaseFile.yaml") as \$d1 | .spec.requirements=\$d1.requirements' | kubectl apply -f -
>&2 echo "Remove release file ..."
rm /tmp/releaseFile.yaml
>&2 echo "Sleep 5 seconds before check..."
sleep 5
>&2 echo "Release status: \$(kubectl get deckhousereleases.deckhouse.io -o 'jsonpath={..status.phase}')"
Expand Down

0 comments on commit 5d971a6

Please sign in to comment.