English 中文(简体)
页: 1 工具sh:在Dev Ops管道运行时没有发现指挥。
原标题:AzureSignTool sh: command not found when run in an Azure DevOps Pipeline

我有一个管道,正在顺利运行,并将我的软件部署到一个集装箱。 我想在《美国刑法》出版之前,在建筑阶段之前,加上签署法典。

我们的证书是用钥匙标识持有的,我正试图使用“SignTool”在部署之前作为试验签署前文件。

在通过AzureSignTool之后,你需要把两项任务补充到你的管道中。 第1个“SatignTool”和第2个“指挥”组织要签署。 我的问题是,在安装这一工具之后,我发现这一错误:

sh: Line 1:SignTool: 未发现

它是一个全球装置,我无法理解为什么会发现它?

值得注意的是,一位前同事写了原管道,选择使用“Unbunto”。 我是用来书写使用Windows服务器的管道的,因此无法确定这是否带来巨大变化。

管道的压缩版:

trigger:
  tags:
    include:
    -  * 
  branches:
    include:
    - develop
    - release/*

variables:
  - group:  CodeSigningVariables  #variable group
  
pool: ubuntu-20.04

stages:

  # Build Project
  - stage: Build
    displayName: Build & Test Project
    jobs:
      - job: Build
        steps:
          - checkout: self
            persistCredentials: true
            clean: true

          - #### BUILD SECTION REDACTED ####

          - task: DotNetCoreCLI@2
            displayName:  Install AzureSignTool 
            inputs:
              command: custom
              custom: tool
              arguments:  update --global azuresigntool 
              
          - task: CmdLine@2
            displayName:  Sign Application 
            inputs:
              script: |
                AzureSignTool sign -kvu $(SigningVaultURL) -kvi $(SigningClientId) -tr $(SigningTimeStamp) -kvt $(SigningTennentId) -kvs $(SigningClientSecret) -kvc $(SigningCertName) -v $(Build.SourcesDirectory)/src/Project/bin/Release/Project.exe

InstallSignTool步骤的产出:

Starting: Install AzureSignTool
==============================================================================
Task         : .NET Core
Description  : Build, test, package, or publish a dotnet application, or run a custom dotnet command
Version      : 2.221.0
Author       : Microsoft Corporation
Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/build/dotnet-core-cli
==============================================================================
Info: .NET Core SDK/runtime 2.2 and 3.0 are now End of Life(EOL) and have been removed from all hosted agents. If you re using these SDK/runtimes on hosted agents, kindly upgrade to newer versions which are not EOL, or else use UseDotNet task to install the required version.
/usr/bin/dotnet tool update --global azuresigntool
Skipping NuGet package signature verification.
Tool  azuresigntool  was reinstalled with the latest stable version (version  4.0.1 ).
Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
Finishing: Install AzureSignTool

The output from the Sign Application step:

Starting: Sign Application
==============================================================================
Task         : Command line
Description  : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows
Version      : 2.231.1
Author       : Microsoft Corporation
Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line
==============================================================================
Generating script.
Script contents:
AzureSignTool sign -kvu https://keyvault.vault.azure.net/ -kvi *** -tr http://timestamp.digicert.com -kvt *** -kvs *** -kvc CertName -v /datadrive/agent/11/s/src/Project/bin/Release/Project.exe
========================== Starting Command Output ===========================
/usr/bin/bash --noprofile --norc /datadrive/agent/_temp/b365c9f0-b063-4456-84b0-ab382de1b5ac.sh
/datadrive/agent/_temp/b365c9f0-b063-4456-84b0-ab382de1b5ac.sh: Line 1:SignTool: 未发现

##[error]Bash exited with code  127 .
Finishing: Sign Application

Any help with this will be greatly appreciated.

问题回答

根据<编码>外国应用步骤的错误产出,指挥线任务正在使用巴什,管道在<代码>上运行。 Hugo linux agents.

“entergraph

您应在<代码>Windows/code>型代理人上运行,以便找到。

“在此处的影像描述”/</a

关于气球剂,无法找到这一工具。

“enterography





相关问题
BlackBerry Code Signing for Multiple OS es

I wanted to do a couple of things and am wondering if they re possible, and if so, how to do them. I was going to make a Virtual Machine to run code-signing in. That way if my computer dies I can ...

.NET Code Signing Pricing

I am looking into options for code signing our company s application, and it seems there are several different providers such as: VeriSign Thawte Comodo GoDaddy Are there pros and cons for each ...

Authenticode checking slows .NET build

In other posts, e.g. Why are signed assemblies slow to load? it is shown how to avoid checking of signed assemblies when an app runs in a non- or slow-connected environment, by using the ...

Device driver code signing for windows XP 32 bit

I have written a device driver for a device but each time I connect the device in windows XP 32 bit, "found new hardware" wizard appears. I am signing the driver using a Comodo code signing ...

Code signing didn t complain when I changed an exe file?

I purchased a code signing certificate and all looks well. When tested inside a clean Virtual PC OS I no longer get the "The Publisher could not be verified" message. So just for grins, using a hex ...

Code sign Error

I have created a new iPhone application.I have two mach machines. I have created the certificate for running application in iPhone in one mac. Can I use the other mac for running the application in ...

热门标签