Sidra.exe Prerequisites command¶
The sidra.exe prerequisites
command checks or installs the needed dependencies for successfully executing the other commands. For this reason, this is usually the first command to be used when starting a Sidra installation. This command will check or install both external dependencies and the internal ones, the ones pertaining to the Sidra solution, such as needed templates.
The external dependencies needed are:
- The .NET Core SDK
- Git, the version control CLI tool
- Azure CLI and extension
The usage options are:
.\sidra.exe prerequisites verify
.\sidra.exe prerequisites setup
.\sidra.exe prerequisites [setup|verify] --help
Please, login (az login
) before executing any Sidra CLI command.
Usage Options¶
1. Verify option¶
This option verifies that AZ CLI with its extension for Azure DevOps and DotNet Sidra templates, are installed on this machine.
2. Setup option¶
This option installs the following prerequisites for Sidra CLI on this machine: AZ CLI with its extension for Azure DevOps and DotNet Sidra templates.
Parameters¶
This parameter determines whether prerelease version of the packages needs to be used or not. The command is able to use-preview
suffix in the packages with this parameter. This parameter will be necessary to install preview templates. Optional. Reset PowerShell after the Setup option is recommendable in order to ensure the usage of the new installed packages.
Known issues¶
Execution as administrator¶
The command may block Sidra.exe if it is not run from an elevated-rights PowerShell console. Sidra.exe is calling the PowerShell engine, which may refuse to download and install the software without informing the caller.
PowerShell restarts may be needed¶
If external dependencies are installed with this command, restart of the PowerShell console will be needed, to allow the hosting process to reload the PATH environment variable. For example, after installing .NET SDK or Git, the tool needs to execute these the dotnet.exe or git.exe to check for the version installed. Without refreshed PATH, these commands cannot be run; this would result in false-positive reporting of missing dependencies when checking with prerequisites verify post software installation.
PowerShell script execution policy¶
The PowerShell script execution policy must allow for the execution of remote scripts. Remember checking the execution policy and change it accordingly, if needed, prior to running the prerequisites command. Check and set using the below commands. If the Process
scope is being used – the safest –, the execution policy may need to be re-set after a PowerShell console restart.
Blockage due to untrusted PowerShell modules¶
There are situations when some of the preloaded PowerShell modules may be untrusted for execution, especially the ones that are needed by Sidra.exe. In such conditions, when attempting to list or check for the required modules, the Sidra.exe may get blocked because the PowerShell engine in the background would silently wait for a user confirmation, with no feedback flowing through Sidra.exe. Hence, if the program seems to be stuck, this can be due to the existence of the untrusted PowerShell modules installed.
Blockage due to Azure CLI automatic upgrades enabled¶
The command 'az version' is being used to verify Azure CLI installation at 'Sidra.exe prerequisites verify'. In the case that Azure CLI automatic upgrades is enabled, when running 'az version' command, user will be asked to upgrade to latest version. Having auto-upgrade
setting set to true will cause Sidra CLI to wait for a never given answer and it will stop the execution.
Change this setting to false by running the following code: