ostree-ng.sh: use non-default ostree ref
Run tests with user-specified ostree ref. The ref needs to be specified in the container build as well (without a URL) to be used for the commit that will be served to the installer. The same variable/ref is also used to retrieve the $UPGRADE_HASH for the final OS test.
This commit is contained in:
parent
f4ec9d8d91
commit
7066b02bf7
1 changed files with 6 additions and 3 deletions
|
|
@ -60,7 +60,7 @@ EOF
|
||||||
|
|
||||||
# Set up variables.
|
# Set up variables.
|
||||||
OSBUILD_COMPOSER_TEST_DATA=/usr/share/tests/osbuild-composer/
|
OSBUILD_COMPOSER_TEST_DATA=/usr/share/tests/osbuild-composer/
|
||||||
OSTREE_REF="rhel/8/${ARCH}/edge"
|
OSTREE_REF="test/rhel/8/${ARCH}/edge"
|
||||||
OS_VARIANT="rhel8-unknown"
|
OS_VARIANT="rhel8-unknown"
|
||||||
TEST_UUID=$(uuidgen)
|
TEST_UUID=$(uuidgen)
|
||||||
IMAGE_KEY="osbuild-composer-ostree-test-${TEST_UUID}"
|
IMAGE_KEY="osbuild-composer-ostree-test-${TEST_UUID}"
|
||||||
|
|
@ -129,7 +129,10 @@ build_image() {
|
||||||
else
|
else
|
||||||
sudo curl --silent --header "Content-Type: application/json" --unix-socket /run/weldr/api.socket http://localhost/api/v1/compose --data "{
|
sudo curl --silent --header "Content-Type: application/json" --unix-socket /run/weldr/api.socket http://localhost/api/v1/compose --data "{
|
||||||
\"blueprint_name\": \"$blueprint_name\",
|
\"blueprint_name\": \"$blueprint_name\",
|
||||||
\"compose_type\": \"$image_type\"
|
\"compose_type\": \"$image_type\",
|
||||||
|
\"ostree\": {
|
||||||
|
\"ref\": \"$OSTREE_REF\"
|
||||||
|
}
|
||||||
}" | tee "$COMPOSE_START"
|
}" | tee "$COMPOSE_START"
|
||||||
fi
|
fi
|
||||||
COMPOSE_ID=$(jq -r '.build_id' "$COMPOSE_START")
|
COMPOSE_ID=$(jq -r '.build_id' "$COMPOSE_START")
|
||||||
|
|
@ -488,7 +491,7 @@ done;
|
||||||
|
|
||||||
# Get ostree commit value.
|
# Get ostree commit value.
|
||||||
greenprint "🕹 Get ostree upgrade commit value"
|
greenprint "🕹 Get ostree upgrade commit value"
|
||||||
UPGRADE_HASH=$(curl ${URL}refs/heads/rhel/8/x86_64/edge)
|
UPGRADE_HASH=$(curl ${URL}refs/heads/"${OSTREE_REF}")
|
||||||
|
|
||||||
# Clean compose and blueprints.
|
# Clean compose and blueprints.
|
||||||
greenprint "🧽 Clean up upgrade blueprint and compose"
|
greenprint "🧽 Clean up upgrade blueprint and compose"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue