Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Signing Action throws an error Error Message: Failed to install signing tool on self-Hosted #1373

Open
nemanja899 opened this issue Dec 24, 2024 · 3 comments · May be fixed by microsoft/nav-arm-templates#233
Labels
bug Something isn't working

Comments

@nemanja899
Copy link

AL-Go version

6.2

Describe the issue

Signing Action is throwing an error

Unexpected error when running action. Error Message: Failed to install signing tool. If you are using a self-hosted runner please make sure you've followed all the steps described in https://aka.ms/algosettings#runs-on., StackTrace: at Install-SigningTool, C:\Users\vmadmin\actions-runner_v3\_work\_actions\microsoft\AL-Go-Actions\v6.2\Sign\Sign.psm1: line 40 <- at Invoke-SigningTool, C:\Users\vmadmin\actions-runner_v3\_work\_actions\microsoft\AL-Go-Actions\v6.2\Sign\Sign.psm1: line 111 <- at <ScriptBlock>, C:\Users\vmadmin\actions-runner_v3\_work\_actions\microsoft\AL-Go-Actions\v6.2\Sign\Sign.ps1: line 69 <- at <ScriptBlock>, C:\Users\vmadmin\actions-runner_v3\_work\_temp\1a50e636-4be1-417d-9c5b-228ecb3dcbdf.ps1: line 3 <- at <ScriptBlock>, C:\Users\vmadmin\actions-runner_v3\_work\_actions\microsoft\AL-Go-Actions\v6.2\Invoke-AlGoAction.ps1: line 17 <- at <ScriptBlock>, C:\Users\vmadmin\actions-runner_v3\_work\_temp\1a50e636-4be1-417d-9c5b-228ecb3dcbdf.ps1: line 2 <- at <ScriptBlock>, <No file>: line 1

Runner is set as self hosted with setup "gitHubRunner": "self-hosted"
Signing key-vault is setup with Org Variable ALGoOrgSettings.

Expected behavior

Expected to work as well as when is not self-hosted runner setup. I have tested it and everything works as expected and is github runner.

This is when is not self-hosted
Image

Steps to reproduce

Runner is created from this link https://aka.ms/getbuildagent It is created on Azure VM. Github tutorial was followd to create github runner on VM.

CI/CD action was started manually, ALGoOrgSettings and AZURE_CREDINTIAL was created for signing and was successful when is not self-hosted.

Additional context (logs, screenshots, etc.)

Image

@nemanja899 nemanja899 added the bug Something isn't working label Dec 24, 2024
@freddydk
Copy link
Contributor

The GetBuildAgent mig not install the right dotnet version - please login to the runner and check that the right dotnet version is present (like mentioned here: #1310)

If that indeed is the case, I will update the GetBuildAgent template.

@nemanja899
Copy link
Author

Thanks, I saw that is says it's not compatible with .NET 7.0. Which is strange since runner is not really that old.
Had also difficult time setting up Key-Vault to work yesterday. Since signing was skipped in new version if Key/Vault is not properly set-up. There was a lot of trials and error.

Even when this is filled
"KeyVaultCertificateUrlSecretName": "CODESIGNCERTIFICATEURL",
"KeyVaultCertificatePasswordSecretName": "CODESIGNCERTIFICATEPASSWORD",
"KeyVaultClientIdSecretName": "KeyVaultClientId",
"KeyVaultName":"signapps",

Signing apps would be skipped if keyVaultCodesignCertificateName is not filled, Does then that make this fields "KeyVaultCertificateUrlSecretName" "KeyVaultCertificatePasswordSecretName" useless? If I already have certificate and password set-up when I did imort .pfx file. Have an option adding password when importing .pfx.

@freddydk
Copy link
Contributor

The settings you mention here are not for code signing - they are for appsource apps getting keyvault access - see: https://github.com/microsoft/AL-Go/blob/main/Scenarios/settings.md#appsource-specific-advanced-settings

The codesigning mechanism today requires you to use a keyvault for the certificate. If you still have a valid .pfx file you can import this to a keyvault and use new signing.

@freddydk freddydk linked a pull request Jan 9, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants