Running Azure Sphere SDK Download and Install in a Pipeline Agent

Austin DeLaRosa 1 Reputation point
2022-09-08T17:19:45.1+00:00

I'm attempting to install the Azure Sphere SDK on a Linux Microsoft-hosted build agent but am running into a wall when attempting to run the installation headless, that is without a user prompt asking me to verify some step prior to installation. Perusing through the .sh script itself the only option that seems reasonable is to simply override the functionality and ship the entire .sh file with my pipeline to run, but then I'm stuck having to manually update the shell script should something shift in the installer.

Below is line 274 in the install_azure_sphere_sdk_2207.sh file referenced in the build article:

user_confirm_or_abort() {
# Takes up to two parameters:
# $1 Confirmation question, to be followed by a localised " (Y/N)", repeated until the user answers
# #2 Optional preamble, not repeated with question. Useful for long confirmation dialogs.
# Commented out to disable user prompt --> if user_confirm "$1" "$2"; then return; else exit_with_error; fi
return;
}

Has anyone else run into this issue, and if so, what resolution is there for having an automated 'yes' option, like one would have during an automated script to update something without user interaction? Appreciate anyone's insights.

Azure Sphere
Azure Sphere
An Azure internet of things security solution including hardware, operating system, and cloud components.
156 questions
{count} votes